Normally I would ask this on a more appropriate site but with my limited knowledge of programming I can only describe the problem here.
I'm trying to make a userscript that will automatically change the current url to the image, and still let me return to the posts' page:
if (history.length === 1) { location.assign($("#image").eq(0).attr("src")); }
The problem with this however, is when I return to the posts' page it acts and looks differently; The shortcut keys don't work, "(vote up/down)" is changed to "(vote up/downunvote)", both "Favorite" and "Unfavorite" are visible, and the comment box is already opened. Picture examples: Normal - Abnormal
Is it something with the cookies? What can I do to stop it from doing that?