I added my code in git using command "git add ." Unfortunately, I pushed my code into git without commit to git. Then, I tried to checkout to main branch, it gave me an warning. But I checked out to main branch forcefully. After that, I went back to my branch and I lost my last added code.
Is there any way to recover my lost code?