diff options
author | Andrey Andreev <narf@devilix.net> | 2015-06-11 16:44:20 +0200 |
---|---|---|
committer | Andrey Andreev <narf@devilix.net> | 2015-06-11 16:44:20 +0200 |
commit | 29de16588458b1abc1b2fb4d125bd9fe04e755c6 (patch) | |
tree | 927e8ad5fff537629a765de6d8f1216a4a99333d /system/libraries/Form_validation.php | |
parent | 38b5eb0cccd06c1819c5c69fc967ce802b39835a (diff) |
Fix #3904
Diffstat (limited to 'system/libraries/Form_validation.php')
-rw-r--r-- | system/libraries/Form_validation.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/system/libraries/Form_validation.php b/system/libraries/Form_validation.php index 36a8148df..0251286ea 100644 --- a/system/libraries/Form_validation.php +++ b/system/libraries/Form_validation.php @@ -618,6 +618,12 @@ class CI_Form_validation { $rules = array(1 => $rule); break; } + elseif (is_array($rule) && isset($rule[0], $rule[1]) && is_callable($rule[1])) + { + $callback = TRUE; + $rules = array($rule[0] => $rule[1]); + break; + } } if ( ! $callback) |