Avoid processing the nil pointer returned by kustomizationResultAdapter

Currently, the crawler job panics whenever a nil pointer is returned by
kustomizationResultAdapter.
This commit is contained in:
Haiyan Meng
2019-12-11 13:54:01 -08:00
parent e4635b456a
commit 0d79219e46

View File

@@ -193,7 +193,9 @@ func processQuery(ctx context.Context, gcl GhClient, query string,
errs = append(errs, err)
errorCnt++
}
output <- k
if k != nil {
output <- k
}
totalCnt++
}