summaryrefslogtreecommitdiffstats
path: root/models/issue_tracked_time.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2017-12-14 07:45:31 +0800
committerGitHub <noreply@github.com>2017-12-14 07:45:31 +0800
commitf94c1b3943ebc4249e6240855c5414f735e8b25f (patch)
tree720895df7e78cd95e3803929332485b5619b611e /models/issue_tracked_time.go
parentb6d2243ac056be7997ef8d14be505873ce34a47e (diff)
downloadgitea-f94c1b3943ebc4249e6240855c5414f735e8b25f.tar.gz
gitea-f94c1b3943ebc4249e6240855c5414f735e8b25f.zip
Improvements for supporting UI Location (#3146)
* improvements for supporting UI Location * improved the comment
Diffstat (limited to 'models/issue_tracked_time.go')
-rw-r--r--models/issue_tracked_time.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/models/issue_tracked_time.go b/models/issue_tracked_time.go
index 3b2360f68f..c314f8f44f 100644
--- a/models/issue_tracked_time.go
+++ b/models/issue_tracked_time.go
@@ -7,6 +7,7 @@ package models
import (
"time"
+ "code.gitea.io/gitea/modules/setting"
api "code.gitea.io/sdk/gitea"
"github.com/go-xorm/builder"
@@ -24,7 +25,7 @@ type TrackedTime struct {
// AfterLoad is invoked from XORM after setting the values of all fields of this object.
func (t *TrackedTime) AfterLoad() {
- t.Created = time.Unix(t.CreatedUnix, 0).Local()
+ t.Created = time.Unix(t.CreatedUnix, 0).In(setting.UILocation)
}
// APIFormat converts TrackedTime to API format