Replace is_null() with === / !== NULL
Exact same behavior, but faster. I also think it's more readable.
diff --git a/system/libraries/Unit_test.php b/system/libraries/Unit_test.php
index de8c9bb..7a67c72 100644
--- a/system/libraries/Unit_test.php
+++ b/system/libraries/Unit_test.php
@@ -356,12 +356,12 @@
*/
protected function _parse_template()
{
- if ( ! is_null($this->_template_rows))
+ if ($this->_template_rows !== NULL)
{
return;
}
- if (is_null($this->_template) OR ! preg_match('/\{rows\}(.*?)\{\/rows\}/si', $this->_template, $match))
+ if ($this->_template === NULL OR ! preg_match('/\{rows\}(.*?)\{\/rows\}/si', $this->_template, $match))
{
$this->_default_template();
return;