In truth, this should be a private method (so prefix with `_`) and be called from `censor_updates`. You should make sure that either

1. `Layer.censor_updates` calls `Layer._apply_constraints` and `censor_updates` in the derived classes always calls `Layer.censor_updates`.
2. Every `censor_updates` in the derived class calls `_apply_constraints` directly.