Third/First Person Camera

I have recently scripted a toggle function for a Third/First Person camera. There was a thing I want to do:

When I wanted to add a “disable input” function to the script, the cameras bugged out and projected the First Person perspective, but from the Third Person camera, meaning i could turn my head in 360 degrees like a Third person camera would. How do i fix this? This is an image of the script: