This might not happen often, but recently I wanted to switch my git user. Working on the same repository but initiated with a different user. To do this, you can use the terminal.
Open a terminal window and retrieve your git info with the command:
git config --list
Here you should see your git repo info. I check this to copy paste the git url. You can use the command
git remote set-url origin https://firstname.lastname@example.org to set the new user in the url.
To trigger the refresh enter the
git pull command, which should prompt you for a new password (since you changed the user). Enter the correct password and after that you are good to go again.