From e0570be5626d68fb82237895b18670ef0ac860e9 Mon Sep 17 00:00:00 2001 From: Jose Diaz-Gonzalez Date: Fri, 25 Dec 2020 00:01:00 -0500 Subject: [PATCH] refactor: use common.VerifyAppName for appExists The duplicative logic didn't make much sense. --- plugins/apps/functions.go | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/plugins/apps/functions.go b/plugins/apps/functions.go index 437706328..9d6b0491a 100644 --- a/plugins/apps/functions.go +++ b/plugins/apps/functions.go @@ -12,15 +12,7 @@ import ( // checks if an app exists func appExists(appName string) error { - if err := common.IsValidAppName(appName); err != nil { - return err - } - - if !common.DirectoryExists(common.AppRoot(appName)) { - return fmt.Errorf("App %s does not exist", appName) - } - - return nil + return common.VerifyAppName() } // checks if an app is locked