mirror of
https://gitee.com/dromara/carbon.git
synced 2024-11-29 18:57:37 +08:00
修复进行 UnmarshalJSON 时时区错误的 bug
This commit is contained in:
parent
d45e1b5266
commit
a65281a61c
@ -105,7 +105,7 @@ type TimestampNano struct {
|
||||
// MarshalJSON implements the interface json.Marshal for Carbon struct.
|
||||
// 实现 json.Marshaler 接口
|
||||
func (c Carbon) MarshalJSON() ([]byte, error) {
|
||||
return []byte(fmt.Sprintf(`"%s"`, c.Layout(c.layout, c.Location()))), nil
|
||||
return []byte(fmt.Sprintf(`"%s"`, c.Layout(c.layout))), nil
|
||||
}
|
||||
|
||||
// UnmarshalJSON implements the interface json.Unmarshal for Carbon struct.
|
||||
|
Loading…
Reference in New Issue
Block a user