From 36631eb7fb497a521b8319e23b7e60bca0080d2b Mon Sep 17 00:00:00 2001 From: Aaron Parecki Date: Wed, 19 Aug 2015 09:42:37 -0700 Subject: [PATCH] fix tz_offset_to_seconds --- lib/helpers.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/helpers.php b/lib/helpers.php index 91ccbeb..6ce4f3d 100644 --- a/lib/helpers.php +++ b/lib/helpers.php @@ -231,7 +231,7 @@ function tz_seconds_to_offset($seconds) { function tz_offset_to_seconds($offset) { if(preg_match('/([+-])(\d{2}):?(\d{2})/', $offset, $match)) { $sign = ($match[1] == '-' ? -1 : 1); - return ($match[2] * 60 * 60) + ($match[3] * 60) * $sign; + return (($match[2] * 60 * 60) + ($match[3] * 60)) * $sign; } else { return 0; }