Fixed toggling dangerous functions immediately displaying correct template restriction