From 5bd3789b740652d93936894905d755a93c4782fa Mon Sep 17 00:00:00 2001 From: shish Date: Sat, 28 Apr 2007 15:46:53 +0000 Subject: [PATCH] make the regex a little neater git-svn-id: file:///home/shish/svn/shimmie2/trunk@23 7f39781d-f577-437e-ae19-be835c7a54ca --- core/database.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/database.class.php b/core/database.class.php index 89b3aec5..77e39a1e 100644 --- a/core/database.class.php +++ b/core/database.class.php @@ -103,7 +103,7 @@ class Database { $args = array(int_escape($matches[2]), int_escape($matches[3])); $img_search->append(new Querylet("AND (width / height $cmp ? / ?)", $args)); } - else if(preg_match("/(filesize|id)(<|>|<=|>=|=)([\dKMGB]+)/i", $term, $matches)) { + else if(preg_match("/(filesize|id)(<|>|<=|>=|=)(\d+[kmg]?b?)/i", $term, $matches)) { $col = $matches[1]; $cmp = $matches[2]; $val = parse_shorthand_int($matches[3]);