fix: Don't bail on unrecognized OAuth scopes

This commit is contained in:
Ginger
2026-10-05 14:22:53 +00:00
committed by Ellis Git
parent 08b6ab4af7
commit af84202ba4
+1 -5
View File
@@ -145,12 +145,8 @@ pub fn to_scopes(&self) -> Result<HashSet<RequestedScope>, String> {
} else if let Some(captures) = device_token_regex.captures(token) {
scopes
.insert(RequestedScope::Device(captures.get(2).unwrap().as_str().into()))
} else if token == "openid" {
// TODO(unspecced): Element sets this scope but doesn't use
// it for anything
true
} else {
return Err(format!("Invalid scope: {token}"));
continue;
}
};