diff options
author | Christian Schneider | 2016-01-13 14:19:35 +0100 |
---|---|---|
committer | Christian Schneider | 2016-01-13 14:19:35 +0100 |
commit | 9fe04aea4c1b245a8f8750729df826b82bdedde4 (patch) | |
tree | cfb138167dd42b167ce14bf8962f6edb0f724db7 /itjs.class | |
parent | 14a2baa53b557c22d6fe4abca6864699c3161b72 (diff) | |
download | itools-9fe04aea4c1b245a8f8750729df826b82bdedde4.tar.gz itools-9fe04aea4c1b245a8f8750729df826b82bdedde4.tar.bz2 itools-9fe04aea4c1b245a8f8750729df826b82bdedde4.zip |
Anchor regex for my peace of mind
Diffstat (limited to 'itjs.class')
-rw-r--r-- | itjs.class | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -133,10 +133,10 @@ static function filenames($filelist) foreach (it::match("[-\w.=?&]+", basename($filelist), array('all' => true)) as $file) # split by comma but ignore illegal chars { - $filenames = $special[$file] ?: (file_exists("$local/" . it::match('[^?]*', $file)) ? "$local/$file" : "$libsearch/itjs/$file"); + $filenames = $special[$file] ?: (file_exists("$local/" . it::match('^[^?]*', $file)) ? "$local/$file" : "$libsearch/itjs/$file"); foreach (explode(",", $filenames) as $filename) - if (!$seen[$filename]++ && file_exists(it::match('[^?]*', $filename))) + if (!$seen[$filename]++ && file_exists(it::match('^[^?]*', $filename))) $result[] = $filename; } |