summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUrban Müller2007-05-08 13:53:10 +0000
committerUrban Müller2007-05-08 13:53:10 +0000
commite9c2d84a068443e4c4cff0ac5ac4ba098eff44f3 (patch)
tree00d3372cc0f4f3df7f6d665111bf2eb76f72d208
parent011f319ee4371438b7640378fec1639277f0442b (diff)
downloaditools-e9c2d84a068443e4c4cff0ac5ac4ba098eff44f3.tar.gz
itools-e9c2d84a068443e4c4cff0ac5ac4ba098eff44f3.tar.bz2
itools-e9c2d84a068443e4c4cff0ac5ac4ba098eff44f3.zip
work correctly if result casted to array
-rw-r--r--it.class2
1 files changed, 1 insertions, 1 deletions
diff --git a/it.class b/it.class
index d1e1400..0866102 100644
--- a/it.class
+++ b/it.class
@@ -222,7 +222,7 @@ function match($pattern, $string, $p = array())
setlocale(LC_CTYPE, $oldlocale);
if (!$r) # no match
- $result = $p['all'] ? array() : false;
+ $result = $p['all'] ? array() : null;
else if (count($m) == 1) # no capture
$result = $m[0];
else if (count($m) == 2) # one capture