Skip to content

Commit

Permalink
Fix compiling errors
Browse files Browse the repository at this point in the history
  • Loading branch information
raman-m committed Oct 19, 2024
1 parent 5b8adff commit af3643a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Ocelot/Configuration/AuthenticationOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public AuthenticationOptions(List<string> allowedScopes, string[] authentication
/// <param name="keys">New <see cref="AuthenticationProviderKeys"/> to build.</param>
private void BuildAuthenticationProviderKeys(string legacyKey, string[] keys)
{
keys ??= new string[];
keys ??= Array.Empty<string>();
if (string.IsNullOrEmpty(legacyKey))
{
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ public AuthenticationOptionsBuilder WithRequiredRole(List<string> requiredRole)

[Obsolete("Use the " + nameof(WithAuthenticationProviderKeys) + " property!")]
public AuthenticationOptionsBuilder WithAuthenticationProviderKey(string authenticationProviderKey)
=> WithAuthenticationProviderKeys([authenticationProviderKey]);
=> WithAuthenticationProviderKeys(authenticationProviderKey);

public AuthenticationOptionsBuilder WithAuthenticationProviderKeys(string[] authenticationProviderKeys)
public AuthenticationOptionsBuilder WithAuthenticationProviderKeys(params string[] authenticationProviderKeys)
{
_authenticationProviderKeys = authenticationProviderKeys;
return this;
Expand Down

0 comments on commit af3643a

Please sign in to comment.