return json.Marshal(&struct {
Path string `json:"path"`
Version string `json:"version"`
- Time *time.Time `json:"time"`
+ Time time.Time `json:"time"`
Owner string `json:"owner"`
Dir string `json:"dir"`
Meta map[string]interface{} `json:"meta"`
return json.Marshal(&struct {
Path string `json:"path"`
Version string `json:"version"`
- Time *time.Time `json:"time"`
+ Time time.Time `json:"time"`
Owner string `json:"owner"`
Dir string `json:"dir"`
Mounts []modMount `json:"mounts"`
Version() string
// Time version was created.
- Time() *time.Time
+ Time() time.Time
// Whether this module's dir is a watch candidate.
Watch() bool
return m.gomod.Version
}
-func (m *moduleAdapter) Time() *time.Time {
+func (m *moduleAdapter) Time() time.Time {
if !m.IsGoMod() || m.gomod.Time == nil {
- return nil
+ return time.Time{}
}
- return m.gomod.Time
+ return *m.gomod.Time
+
}
func (m *moduleAdapter) Watch() bool {