I moved the logic of removing the hidden class into the switch case of MODE_PLAYER, so it should be no problem just like the other cases.