Skip to content

Commit

Permalink
Added "No Application Installed" Log When Updating & No Application i…
Browse files Browse the repository at this point in the history
…s Installed
  • Loading branch information
pegvin committed Apr 3, 2022
1 parent 1fc54a2 commit 3d9e5e6
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/commands/update.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,19 @@ func (cmd *UpdateCmd) Run() (err error) {
// Variable which will hold if any app was updated.
var howManyUpdates int = 0

fmt.Println("Checking For Updates")

if cmd.All { // if `update all`
cmd.Targets, err = getAllTargets() // Load all the application info into targets
if err != nil {
return err
}
}

if len(cmd.Targets) == 0 {
fmt.Println("No Application Installed")
return nil
}

fmt.Println("Checking For Updates")
for _, target := range cmd.Targets {
if len(strings.Split(target, "/")) < 2 {
target = strings.ToLower(target + "/" + target)
Expand Down

0 comments on commit 3d9e5e6

Please sign in to comment.