cakephp / docs

CakePHP CookBook
http://book.cakephp.org
Other
681 stars 2.58k forks source link

4.x hidden BC break => migration guide #6075

Closed dereuromark closed 5 years ago

dereuromark commented 5 years ago

Currently, if you upgrade forms (or other parts) using the following hook:

protected function _buildValidator(Validator $validator): Validator {}

You will now silently have a passing form (no validation anymore at all) because the callback is never executed.

We need to document this in the guide for those cases - or add dummy hooks that trigger deprecation/exception.

It is now:

public function validationDefault(Validator $validator): Validator {}
markstory commented 5 years ago

Would it be reasonable to emit a deprecation warning during construction? We could check for the existence of that method and then emit a deprecation warning.

dereuromark commented 5 years ago

Will this go into core? Otherwise we would need to add it to Shim plugin, but then only a few people will have this warning.

markstory commented 5 years ago

I can add a deprecation.

arbims commented 4 years ago

@markstory hello i want to ask if the documentation for cakephp4 is rady i can create my website with this version ?? thnx