#!/bin/sh
set -- remove
case "$1" in
  remove|purge|0|"") ;;
  *) exit 0 ;;  # an upgrade must keep the watcher running
esac
if command -v systemctl >/dev/null 2>&1; then
  systemctl disable --now "initmax-widget-deploy-navigatormax.path" >/dev/null 2>&1 || true
  systemctl stop "initmax-widget-deploy-navigatormax.service" >/dev/null 2>&1 || true
fi
exit 0
