From 970b6806c75c6b5a0e5ee1e319a68a0d87e7d744 Mon Sep 17 00:00:00 2001 From: Jose Diaz-Gonzalez Date: Fri, 27 Apr 2018 00:28:17 -0400 Subject: [PATCH] fix: do not output error message twice It was output twice because stderr is not silenced and `get_running_image_tag` was called _before_ `verify_app_name`. --- plugins/apps/functions | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugins/apps/functions b/plugins/apps/functions index 3fdc9ef0c..24d8d7ee4 100755 --- a/plugins/apps/functions +++ b/plugins/apps/functions @@ -16,8 +16,10 @@ apps_create() { } apps_destroy() { - local APP="$1"; local IMAGE_TAG=$(get_running_image_tag "$APP") + declare desc="destroys an app" + declare APP="$1"; verify_app_name "$APP" + local IMAGE_TAG=$(get_running_image_tag "$APP") if [[ -z "$DOKKU_APPS_FORCE_DELETE" ]]; then dokku_log_warn "WARNING: Potentially Destructive Action"