The Problem
OK, so, I had two branches: main and session
In the main branch I developed the main code, in the session branch I developed code for a new session system.
Occasionally, I merged main into session to keep it up to date. ("Merge branch 'main' into session").
Today I felt the new session system was ready, and merged main into session so that it's on par with main, before merging session into main.
I finally merged session into main, was happy that this long in progress feature is done, and to really feel like I was done, I deleted the session branch.
Now, I didn't notice at the time, but it seems Git did fast-forward (or something like that), and the main branch has essentially become the session branch.
This means instead of having one nice merge commit seeing all the changes from session, they're all spread out, since it's now effectively the session branch. Not only is this terrible for historic purposes, but it also effectively prevents me from undoing this merge if the need arises.
What I tried
Git reflog: There are many sources online that share the trick with git reflog to restore a branch, however this does not seem to work for me, since the main branch has essentially become the session branch.
Undo the latest (merge) commit: This also does not work for me, since the latest commit is now "merge branch 'main' into session", so that too undoes all changes to main.
Further explanation
So, the last commit is not session branch stuff, but rather main branch stuff merged into main branch (since main has been turned into session, apparently).
Again, due to the regular merges and then a fast-forward, I essentially turned the main branch into the session branch. How can I undo this?
Apologies if I'm repeating myself, I'm just trying to describe as best as I can to make the issue clear.