1
0
mirror of https://github.com/matrix-org/matrix-authentication-service.git synced 2025-07-28 11:02:02 +03:00

storage: OAuth2 client repository

This commit is contained in:
Quentin Gliech
2023-01-04 14:48:29 +01:00
parent caf7770921
commit 09a567ab17
15 changed files with 833 additions and 639 deletions

View File

@ -90,6 +90,11 @@ impl<T> Localized<T> {
&self.non_localized
}
/// Get the non-localized variant.
pub fn to_non_localized(self) -> T {
self.non_localized
}
/// Get the variant corresponding to the given language, if it exists.
pub fn get(&self, language: Option<&LanguageTag>) -> Option<&T> {
match language {