#!/bin/sh

ssr_enable=$(uci get ssrpro.@ssrpro[0].enabled 2>/dev/null)

if [ $ssr_enable -eq 1 ]; then
	if pidof ssr-redir>/dev/null; then
	   /etc/init.d/ssrpro reload_rule
	 else
	   /etc/init.d/ssrpro restart
  fi
fi
