DCHP server remains on network after removal of Router

Hi,
Sorry for resurrecting this thread but I have re-posted the updated script in the original thread in case you still need it.
https://forum.gl-inet.com/t/bug-report-mt300n-v2-fw-2-261-dhcpv6-still-active-in-bridge-mode/2359/5
switch_mode.zip