Skip to content

Commit

Permalink
Update commands check
Browse files Browse the repository at this point in the history
  • Loading branch information
Aditi Sharma committed Jun 1, 2020
1 parent a32f898 commit c8b3233
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/devfile/adapters/common/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,12 @@ func validateCommand(data data.DevfileData, command common.DevfileCommand) (err
}

// component must be specified
if &command.Exec.Component == nil || command.Exec.Component == "" {
if command.Exec.Component == "" {
return fmt.Errorf("Exec commands must reference a component")
}

// must specify a command
if &command.Exec.CommandLine == nil || command.Exec.CommandLine == "" {
if command.Exec.CommandLine == "" {
return fmt.Errorf("Exec commands must have a command")
}

Expand Down

0 comments on commit c8b3233

Please sign in to comment.