Skip to content

Commit a69ba12

Browse files
committed
Return empty array if are no installations
1 parent 8544d7d commit a69ba12

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

internal/installations.go

+5
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,11 @@ func Installations(c *cli.Context) error {
6262
return fmt.Errorf("failed marshalling installations to JSON: %w", err)
6363
}
6464

65+
if len(*installations) < 1 {
66+
fmt.Println("[]")
67+
return nil
68+
}
69+
6570
fmt.Println(string(bytes))
6671

6772
return nil

0 commit comments

Comments
 (0)