Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

make sure a missing validation rule always triggers a warning (in pro…

…ductive mode this will be logged in the log files)
  • Loading branch information...
commit 760cf33ce377ae8e4f1548fb69891f078677ee53 1 parent 70ac1c7
@dereuromark dereuromark authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/Cake/Model/Validator/CakeValidationRule.php
View
2  lib/Cake/Model/Validator/CakeValidationRule.php
@@ -274,7 +274,7 @@ public function process($field, &$data, &$methods) {
$this->_valid = call_user_func_array(array('Validation', $this->_rule), $this->_ruleParams);
} elseif (is_string($validator['rule'])) {
$this->_valid = preg_match($this->_rule, $data[$field]);
- } elseif (Configure::read('debug') > 0) {
+ } else {
trigger_error(__d('cake_dev', 'Could not find validation handler %s for %s', $this->_rule, $field), E_USER_WARNING);
return false;
}
Please sign in to comment.
Something went wrong with that request. Please try again.