[7.4-stable] Fix exception in admin when current language is deleted#3791
Merged
tvdeyen merged 1 commit into7.4-stablefrom Mar 26, 2026
Merged
[7.4-stable] Fix exception in admin when current language is deleted#3791tvdeyen merged 1 commit into7.4-stablefrom
tvdeyen merged 1 commit into7.4-stablefrom
Conversation
This fixes a situation where the session contains a language id for a language that no longer exists because it has been deleted. This commit fixes this in two ways: - when deleting the language, it is removed from the session if the language is identical - when trying to get the language from the session id, the lookup code now falls back to the default language if it can't be found. This is meant to fix the scenario where a different user deletes the language instead of the user with the language id in the session I believe both fixes are useful. I've tried to come up with meaningful tests but I am somewhat unfamiliar with the codebase so feel free to suggest extra things. A backport to Alchemy 7 would be appreciated if possible, as it will probably still take us a while to get to 8. (cherry picked from commit 380d62c)
3 tasks
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## 7.4-stable #3791 +/- ##
===========================================
Coverage 96.53% 96.53%
===========================================
Files 239 239
Lines 6487 6490 +3
===========================================
+ Hits 6262 6265 +3
Misses 225 225 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
tvdeyen
approved these changes
Mar 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport
This will backport the following commits from
mainto7.4-stable:Questions ?
Please refer to the Backport tool documentation