Toggle with key input only turning off

Very noob question and I’ve tried to see if this was answered somewhere else but couldn’t find a solution.

This is the code I’m using. The problem I’m having is that the object disappears, but when I press the assigned key again, it won’t reappear which is what I’d like for it to do.

I don’t know much about coding and I’m just starting to learn.

public GameObject glasses;
    // Update is called once per frame
    void Update()
    {
 	if (Input.GetButtonDown("glassesKey"))
     	glasses.SetActive(!glasses.activeSelf);
        
    }

Quick question is this script on the glasses object?

If so, you are disabling the object that looks for your key input! Try putting this script on the camera.