Skip to content

Commit

Permalink
Fix nil exception
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexGustafsson committed Dec 16, 2024
1 parent d468317 commit 169ad69
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/worker/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func (w *Worker) ProcessRawImage(ctx context.Context, reference oci.Reference) e
// Add tags based on version diff
currentVersion, currentVersionErr := oci.ParseVersion(data.ImageReference.Version())
newVersion, newVersionErr := oci.ParseVersion(data.LatestReference.Version())
if currentVersionErr == nil && newVersionErr == nil {
if currentVersion != nil && currentVersionErr == nil && newVersion != nil && newVersionErr == nil {
diff := currentVersion.Diff(newVersion)
if diff != "" {
data.Tags = append(data.Tags, diff)
Expand Down

0 comments on commit 169ad69

Please sign in to comment.