feat: add app name verification to all golang plugins
Moving verification of input to the earliest place is the best way to decrease the need to validate this further downstream. Additionally, some of the existing checks were.... lacking :)
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
package logs
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"strconv"
|
||||
|
||||
@@ -10,10 +9,6 @@ import (
|
||||
|
||||
// CommandDefault displays recent log output
|
||||
func CommandDefault(appName string, num int64, process string, tail, quiet bool) error {
|
||||
if appName == "" {
|
||||
return errors.New("Please specify an app to run the command on")
|
||||
}
|
||||
|
||||
if err := common.VerifyAppName(appName); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user