fix 'nil' panic

This commit is contained in:
Jeff Carr 2025-09-04 15:10:35 -05:00
parent 076bdfb9c6
commit 89e6fd0805
1 changed files with 1 additions and 1 deletions

View File

@ -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)