Moved the camera and now unity stopped recognizing it as main camera

I had a working camera.main code, then I moved my main camera to be a child of a player.
Still worked fine.

Then I unchild it and tried adding a script, this immediately poped errors on every line I have camera.main saying there is no such thing -
"Camera does not contain definition for “main” "

I tried untagging and retaggins it, deleting and creating a new camera, copying the camera again from a different scene, but nothing works, seems unity refuses to recognize the MainCamera tag.

Or am I missing something?

  1. Is the camera tagged as “MainCamera”?
  2. Is the camera enabled?
  3. Check that you’re referring to it as Camera.main, not camera.main.