fixed mode switcher not checking permissions