fix 'nil' panic
This commit is contained in:
parent
076bdfb9c6
commit
89e6fd0805
|
@ -49,7 +49,6 @@ func (f *Forge) loadUpstreamPatchsets(psets *Patchsets) {
|
|||
for all.Scan() {
|
||||
pset := all.Next()
|
||||
found := f.Patchsets.FindByUuid(pset.Uuid)
|
||||
author := log.Sprintf("Author: %s <%s>", found.GitAuthorName, found.GitAuthorEmail)
|
||||
if found == nil {
|
||||
log.Info("new patchset", pset.Name, pset.Uuid)
|
||||
pset.State = "new"
|
||||
|
@ -66,6 +65,7 @@ func (f *Forge) loadUpstreamPatchsets(psets *Patchsets) {
|
|||
f.Patchsets.Append(pset)
|
||||
continue
|
||||
}
|
||||
author := log.Sprintf("Author: %s <%s>", found.GitAuthorName, found.GitAuthorEmail)
|
||||
log.Info("EXAMINE PSET", pset.Name, pset.Uuid, pset.Patches.Len())
|
||||
for _, patch := range pset.Patches.Patches {
|
||||
// log.Info("\tnew patch:", i, patch.CommitHash, patch.Namespace)
|
||||
|
|
Loading…
Reference in New Issue