diff options
author | Andrey Andreev <narf@bofh.bg> | 2012-02-29 18:02:46 +0100 |
---|---|---|
committer | Andrey Andreev <narf@bofh.bg> | 2012-02-29 18:02:46 +0100 |
commit | db0c06247949a4def38bcb0c0cf1239312140a81 (patch) | |
tree | 56a98e57365cd02fc1685617162c5ec26e3ce055 /system | |
parent | 0df831d31f00d1b00b17a452dec04a17aaeb825f (diff) |
Change end() usage due to E_STRICT messages
Diffstat (limited to 'system')
-rw-r--r-- | system/database/DB_active_rec.php | 3 | ||||
-rw-r--r-- | system/helpers/download_helper.php | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/system/database/DB_active_rec.php b/system/database/DB_active_rec.php index 424735157..eaae23f30 100644 --- a/system/database/DB_active_rec.php +++ b/system/database/DB_active_rec.php @@ -236,7 +236,8 @@ class CI_DB_active_record extends CI_DB_driver { { if (strpos($item, '.') !== FALSE) { - return end(explode('.', $item)); + $item = explode('.', $item); + return end($item); } return $item; diff --git a/system/helpers/download_helper.php b/system/helpers/download_helper.php index 34380cc88..a8c59c2c0 100644 --- a/system/helpers/download_helper.php +++ b/system/helpers/download_helper.php @@ -70,7 +70,8 @@ if ( ! function_exists('force_download')) return FALSE; } - $extension = end(explode('.', $filename)); + $extension = explode('.', $filename); + $extension = end($extension); // Load the mime types if (defined('ENVIRONMENT') && is_file(APPPATH.'config/'.ENVIRONMENT.'/mimes.php')) |