#!/opt/bin/sh

echo -e "\n\t*** Extended GUI ***\n\n Executing pre-removal script...\n\n"

# services
if [ -f "/opt/etc/init.d/S32vnstat" ]; then
  if [ -n "$(pidof vnstatd)" ]; then
    /opt/etc/init.d/S32vnstat stop
  fi
fi

if [ -f "/opt/etc/init.d/S80uhttpd" ]; then
  if [ -n "$(pidof uhttpd)" ]; then
    /opt/etc/init.d/S80uhttpd stop
  fi
fi

if [ -f "/opt/etc/init.d/S88shellinaboxd" ]; then
  if [ -n "$(pidof shellinaboxd)" ]; then
    /opt/etc/init.d/S88shellinaboxd stop
  fi
fi
