Created
May 13, 2019 17:39
-
-
Save dbridges/2dc63c9f5da178923da11d2384c5ac5b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func (a *atomTime) Time() time.Time { | |
return time.Time(*a) | |
} | |
func (a *atomTime) LocalString() string { | |
loc, err := time.LoadLocation("Local") | |
if err != nil { | |
return a.Time().String() | |
} | |
return a.Time().In(loc).Format("Jan 02, 2006 3:04PM") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment