summaryrefslogtreecommitdiffstats
path: root/system/libraries/Form_validation.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-11-23 16:33:21 +0100
committerAndrey Andreev <narf@bofh.bg>2012-11-23 16:33:21 +0100
commit2d48b4f1a174473fa0539769a433ba78305c0faa (patch)
tree53f7d2b30d9100c5d5b6e4c0bd8125e5630bf571 /system/libraries/Form_validation.php
parent1b7a452c8331adbd306d3ab9d776a9ae073f1243 (diff)
Fix #113
Diffstat (limited to 'system/libraries/Form_validation.php')
-rw-r--r--system/libraries/Form_validation.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/system/libraries/Form_validation.php b/system/libraries/Form_validation.php
index 7056558c5..b65c4881c 100644
--- a/system/libraries/Form_validation.php
+++ b/system/libraries/Form_validation.php
@@ -496,7 +496,8 @@ class CI_Form_validation {
return isset($array[$keys[$i]]) ? $this->_reduce_array($array[$keys[$i]], $keys, ($i+1)) : NULL;
}
- return $array;
+ // NULL must be returned for empty fields
+ return ($array === '') ? NULL : $array;;
}
// --------------------------------------------------------------------