Added edge case check for oauth2 service
This commit is contained in:
parent
f8fdc22bb0
commit
02cf5e99e5
|
@ -26,7 +26,9 @@ public class OAuth2Service
|
|||
|
||||
var config = ConfigService.GetSection("Moonlight").GetSection("OAuth2");
|
||||
|
||||
Configs = config.GetSection("Providers").Get<OAuth2ProviderConfig[]>();
|
||||
Configs = config.GetSection("Providers").Get<OAuth2ProviderConfig[]>()
|
||||
?? Array.Empty<OAuth2ProviderConfig>();
|
||||
|
||||
OverrideUrl = config.GetValue<string>("OverrideUrl");
|
||||
EnableOverrideUrl = config.GetValue<bool>("EnableOverrideUrl");
|
||||
AppUrl = configService.GetSection("Moonlight").GetValue<string>("AppUrl");
|
||||
|
|
Loading…
Reference in a new issue