From 3942cd7c4db9ebf77e9bfa14638f36f9bd682f91 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sun, 8 Apr 2018 17:31:45 +0100 Subject: [PATCH] Remove node apps after stopping daemon --- src/freedombone-template | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/freedombone-template b/src/freedombone-template index 95364def..8d06a922 100755 --- a/src/freedombone-template +++ b/src/freedombone-template @@ -579,14 +579,6 @@ echo ' fi' echo '}' echo '' echo "function remove_${app_name} {" -if [ "$app_nodeapp" ]; then - echo " npm uninstall -g ${app_nodeapp}" - echo '' -fi -if [[ "$app_node" == 'yes' ]]; then - echo " remove_nodejs ${app_name}" - echo '' -fi echo " nginx_dissite \"\$${app_name_upper}_DOMAIN_NAME\"" echo " remove_certs \"\$${app_name_upper}_DOMAIN_NAME\"" echo '' @@ -598,6 +590,14 @@ if [ $app_daemon ]; then echo ' fi' echo " userdel -r ${app_name}" fi +if [ "$app_nodeapp" ]; then + echo " npm uninstall -g ${app_nodeapp}" + echo '' +fi +if [[ "$app_node" == 'yes' ]]; then + echo " remove_nodejs ${app_name}" + echo '' +fi if [ $app_webui ]; then echo '' echo " if [ -d \"/var/www/\$${app_name_upper}_DOMAIN_NAME\" ]; then"