setting up to restrict switch behaviour