Fun fact: Lemmy (well, pict-rs) tries to keep rotation when stripping tags but fails on certain formats. Funnily enough, it calls imagemagick to do this.
I submitted a PR a few weeks ago to make the fallback tag stripper keep the orientation tag but I don't think the fix has been applied :/
Actually it's even worse because the repo for pict-rs is on the Dev's private gitea instance and to submit a PR I had to do it the kernel.org way by email and they just went "I can't reproduce can you tell me more" and I'm like "I cannot I do not know rust, I just know that this is how you can strip all tags and keep orientation" and never got a response.
Maybe I should fork it and offer my fix and instance admins can choose. :/
Well I mean the code is open. You can search for it, read it and even clone it, you just can't create an account to open a PR or an issue for that matter.