Skip to content

Commit

Permalink
Strict comparison between timezone strings
Browse files Browse the repository at this point in the history
  • Loading branch information
bcrowe committed Dec 19, 2013
1 parent 411093e commit 0b92a20
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Cake/Utility/Time.php
Expand Up @@ -282,7 +282,7 @@ public static function fromString($dateString, $timezone = null) {
$date = intval($dateString);
} elseif (
$dateString instanceof \DateTime &&
$dateString->getTimezone()->getName() != date_default_timezone_get()
$dateString->getTimezone()->getName() !== date_default_timezone_get()
) {
$clone = clone $dateString;
$clone->setTimezone(new \DateTimeZone(date_default_timezone_get()));
Expand Down

0 comments on commit 0b92a20

Please sign in to comment.