diff options
author | Alex Bilbie <alex@alexbilbie.com> | 2012-09-03 19:58:29 +0200 |
---|---|---|
committer | Alex Bilbie <alex@alexbilbie.com> | 2012-09-03 19:58:29 +0200 |
commit | ffeaf809d5d1fbb0a506ff2fcdc9cbe2c657e1e4 (patch) | |
tree | f0337dc5c2566bf53f260f08d39547aa2f7858be /system/helpers/captcha_helper.php | |
parent | 5e9710842dc6981f4eb03c1622eabee9b3171dea (diff) | |
parent | e775b864b741ee0a44b09739c18e71abdadc1291 (diff) |
Merge branch 'develop' of github.com:EllisLab/CodeIgniter into codeigniter/develop
Diffstat (limited to 'system/helpers/captcha_helper.php')
-rw-r--r-- | system/helpers/captcha_helper.php | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/system/helpers/captcha_helper.php b/system/helpers/captcha_helper.php index a4383c9d3..57ef9e2fa 100644 --- a/system/helpers/captcha_helper.php +++ b/system/helpers/captcha_helper.php @@ -80,8 +80,7 @@ if ( ! function_exists('create_captcha')) $current_dir = @opendir($img_path); while ($filename = @readdir($current_dir)) { - if ($filename !== '.' && $filename !== '..' && $filename !== 'index.html' - && (str_replace('.jpg', '', $filename) + $expiration) < $now) + if (strpos($filename, ".jpg") !== FALSE && (str_replace('.jpg', '', $filename) + $expiration) < $now) { @unlink($img_path.$filename); } |