Because you mistakenly started the application as root, its settings folder in your user profile is now owned by root. There are two ways to fix this:
Delete the folder using sudo rm $HOME/.config/Code
Take ownership with sudo chown -R owner:owner $HOME/.config/Code
Never run a program using as root unless you’re going to make system changes. An IDE is not something that needs to run as root.
If you decide to install VS Code in /opt (where it arguably belongs) or any other “global” location, make sure to use the proper umask, so regular users can read and execute files afterwards:
Best Answer
Good luck!