diff --git a/lib/Cake/Console/Command/Task/ExtractTask.php b/lib/Cake/Console/Command/Task/ExtractTask.php index b6ac07302..d616839cd 100644 --- a/lib/Cake/Console/Command/Task/ExtractTask.php +++ b/lib/Cake/Console/Command/Task/ExtractTask.php @@ -398,7 +398,7 @@ class ExtractTask extends AppShell { } list($type, $string, $line) = $countToken; - if (($type == T_STRING) && ($string == $functionName) && ($firstParenthesis === '(')) { + if (($type == T_STRING) && ($string === $functionName) && ($firstParenthesis === '(')) { $position = $count; $depth = 0; diff --git a/lib/Cake/Test/Case/Network/Email/CakeEmailTest.php b/lib/Cake/Test/Case/Network/Email/CakeEmailTest.php index b91e66e80..76be238c2 100644 --- a/lib/Cake/Test/Case/Network/Email/CakeEmailTest.php +++ b/lib/Cake/Test/Case/Network/Email/CakeEmailTest.php @@ -2096,7 +2096,7 @@ class CakeEmailTest extends CakeTestCase { $result['html'] = false; $length = count($message); for ($i = 0; $i < $length; ++$i) { - if ($message[$i] == $boundary) { + if ($message[$i] === $boundary) { $flag = false; $type = ''; while (!preg_match('/^$/', $message[$i])) { diff --git a/lib/Cake/Test/Case/Utility/DebuggerTest.php b/lib/Cake/Test/Case/Utility/DebuggerTest.php index 7c5ec5802..0379e4f4d 100644 --- a/lib/Cake/Test/Case/Utility/DebuggerTest.php +++ b/lib/Cake/Test/Case/Utility/DebuggerTest.php @@ -540,8 +540,8 @@ TEXT; Debugger::dump($var, 1); $result = ob_get_clean(); - $open = php_sapi_name() == 'cli' ? "\n" : '
';
-		$close = php_sapi_name() == 'cli' ? "\n" : '
'; + $open = php_sapi_name() === 'cli' ? "\n" : '
';
+		$close = php_sapi_name() === 'cli' ? "\n" : '
'; $expected = << array( diff --git a/lib/Cake/Utility/String.php b/lib/Cake/Utility/String.php index b6c1b79da..422c1d39d 100644 --- a/lib/Cake/Utility/String.php +++ b/lib/Cake/Utility/String.php @@ -132,21 +132,21 @@ class String { } if ($tmpOffset !== -1) { $buffer .= substr($data, $offset, ($tmpOffset - $offset)); - if (!$depth && $data{$tmpOffset} == $separator) { + if (!$depth && $data{$tmpOffset} === $separator) { $results[] = $buffer; $buffer = ''; } else { $buffer .= $data{$tmpOffset}; } - if ($leftBound != $rightBound) { - if ($data{$tmpOffset} == $leftBound) { + if ($leftBound !== $rightBound) { + if ($data{$tmpOffset} === $leftBound) { $depth++; } - if ($data{$tmpOffset} == $rightBound) { + if ($data{$tmpOffset} === $rightBound) { $depth--; } } else { - if ($data{$tmpOffset} == $leftBound) { + if ($data{$tmpOffset} === $leftBound) { if (!$open) { $depth++; $open = true; diff --git a/lib/Cake/View/Helper/CacheHelper.php b/lib/Cake/View/Helper/CacheHelper.php index f72c9b1e6..2740f9c09 100644 --- a/lib/Cake/View/Helper/CacheHelper.php +++ b/lib/Cake/View/Helper/CacheHelper.php @@ -121,7 +121,7 @@ class CacheHelper extends AppHelper { $index = null; foreach ($keys as $action) { - if ($action == $this->request->params['action']) { + if ($action === $this->request->params['action']) { $index = $action; break; }