Expose available languages publicly#2649
Open
cicnavi wants to merge 1 commit into
Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #2649 +/- ##
=========================================
Coverage 46.75% 46.76%
- Complexity 4288 4290 +2
=========================================
Files 184 184
Lines 13828 13830 +2
=========================================
+ Hits 6465 6467 +2
Misses 7363 7363 🚀 New features to boost your workflow:
|
Member
|
Makes sense @cicnavi ! Code looks good. |
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.
I'm implementing support for
ui_localesparemeter foroidcmodule simplesamlphp/simplesamlphp-module-oidc#350I need to know langauages supported by SSP, and my initial thought was to rely on
language.availableconfg option, but now I see there is additional handling in SSP method\SimpleSAML\Locale\Language::getInstalledLanguageswhich is used to populateavailableLanguagesproperty. So I propose to make a public getter for that property so this can be fetched by other consumers...Also, in the constructor there is a step which checks for language request parameter in $_GET and, if set, uses it to set the language. I would propose a switch which can be used to turn this off, so when I call it from
oidcI don't have this side effect.This all should be fully backward compatible.
I see there is a public method
\SimpleSAML\Locale\Language::getLanguageList, but I would rather propose also adding getter foravailableLanguages, if you don't mind.