From aa462baa33bf0c85448e9d7779d81ab70827b56f Mon Sep 17 00:00:00 2001 From: Steven Barth Date: Thu, 31 Jul 2008 09:04:30 +0000 Subject: [PATCH] Fixed a small bug in timezone generation --- modules/admin-full/luasrc/model/cbi/admin_system/system.lua | 2 +- modules/admin-mini/luasrc/model/cbi/mini/system.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/admin-full/luasrc/model/cbi/admin_system/system.lua b/modules/admin-full/luasrc/model/cbi/admin_system/system.lua index 4e6342d7e..6cc5c495f 100644 --- a/modules/admin-full/luasrc/model/cbi/admin_system/system.lua +++ b/modules/admin-full/luasrc/model/cbi/admin_system/system.lua @@ -23,7 +23,7 @@ s:option(Value, "hostname", translate("hostname")) tz = s:option(ListValue, "timezone", translate("timezone")) for k, offset in luci.util.vspairs(luci.http.protocol.date.TZ) do local zone = k:upper() - local osgn = (offset > 0 and "" or "+") + local osgn = (offset >= 0 and "" or "+") local ohrs = math.floor(-offset / 3600) local omin = (offset % 3600) / 60 diff --git a/modules/admin-mini/luasrc/model/cbi/mini/system.lua b/modules/admin-mini/luasrc/model/cbi/mini/system.lua index 06064f95e..298c794f5 100644 --- a/modules/admin-mini/luasrc/model/cbi/mini/system.lua +++ b/modules/admin-mini/luasrc/model/cbi/mini/system.lua @@ -23,7 +23,7 @@ s:option(Value, "hostname", translate("hostname")) tz = s:option(ListValue, "timezone", translate("timezone")) for k, offset in luci.util.vspairs(luci.http.protocol.date.TZ) do local zone = k:upper() - local osgn = (offset > 0 and "" or "+") + local osgn = (offset >= 0 and "" or "+") local ohrs = math.floor(-offset / 3600) local omin = (offset % 3600) / 60 -- 2.25.1