refactor: drop extra internal calls to VerifyAppName

These are duplicative of the checks that happen at the subcommand level.
This commit is contained in:
Jose Diaz-Gonzalez
2020-12-25 00:08:52 -05:00
parent e0570be562
commit 65d7fd9cce
7 changed files with 0 additions and 59 deletions

View File

@@ -26,10 +26,6 @@ var (
// BuildConfig builds network config files
func BuildConfig(appName string) error {
if err := common.VerifyAppName(appName); err != nil {
return err
}
if !common.IsDeployed(appName) {
return nil
}

View File

@@ -104,14 +104,6 @@ func TriggerNetworkGetProperty(appName string, property string) {
// TriggerNetworkWriteIpaddr writes the ip to disk
func TriggerNetworkWriteIpaddr(appName string, processType string, containerIndex string, ip string) {
if appName == "" {
common.LogFail("Please specify an app to run the command on")
}
err := common.VerifyAppName(appName)
if err != nil {
common.LogFail(err.Error())
}
appRoot := common.AppRoot(appName)
filename := fmt.Sprintf("%v/IP.%v.%v", appRoot, processType, containerIndex)
f, err := os.Create(filename)
@@ -129,14 +121,6 @@ func TriggerNetworkWriteIpaddr(appName string, processType string, containerInde
// TriggerNetworkWritePort writes the port to disk
func TriggerNetworkWritePort(appName string, processType string, containerIndex string, port string) {
if appName == "" {
common.LogFail("Please specify an app to run the command on")
}
err := common.VerifyAppName(appName)
if err != nil {
common.LogFail(err.Error())
}
appRoot := common.AppRoot(appName)
filename := fmt.Sprintf("%v/PORT.%v.%v", appRoot, processType, containerIndex)
f, err := os.Create(filename)