#!/bin/sh

uci -q batch <<-EOF >/dev/null
	delete firewall.timecontrol
	set firewall.timecontrol=include
	set firewall.timecontrol.type=script
	set firewall.timecontrol.path=/var/etc/timecontrol.include
	set firewall.timecontrol.reload=1
EOF

uci -q batch <<-EOF >/dev/null
	delete ucitrack.@timecontrol[-1]
	add ucitrack timecontrol
	set ucitrack.@timecontrol[-1].init=timecontrol
	commit ucitrack
EOF

rm -rf /tmp/luci-*cache
exit 0
