diff options
author | vlakoff <vlakoff@gmail.com> | 2013-01-14 01:30:09 +0100 |
---|---|---|
committer | vlakoff <vlakoff@gmail.com> | 2013-01-14 01:30:09 +0100 |
commit | 1228fe27bc1f22838cd80c5fe33c37274faf0e24 (patch) | |
tree | 897f37e872fde0863b36a70effc9441ac0dfb529 /system/libraries/Javascript.php | |
parent | 5a519db2c4884a3972dd33e09d0b3a314aa222e2 (diff) |
Replace is_null() with === / !== NULL
Exact same behavior, but faster. I also think it's more readable.
Diffstat (limited to 'system/libraries/Javascript.php')
-rw-r--r-- | system/libraries/Javascript.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/system/libraries/Javascript.php b/system/libraries/Javascript.php index 542a0ecde..7f1d85511 100644 --- a/system/libraries/Javascript.php +++ b/system/libraries/Javascript.php @@ -737,7 +737,7 @@ class CI_Javascript { { // JSON data can optionally be passed to this function // either as a database result object or an array, or a user supplied array - if ( ! is_null($result)) + if ($result !== NULL) { if (is_object($result)) { @@ -823,7 +823,7 @@ class CI_Javascript { */ protected function _prep_args($result, $is_key = FALSE) { - if (is_null($result)) + if ($result === NULL) { return 'null'; } |