Browse Source
Merge pull request #446 from colinin/5.0.0
fix(dapr): check the extension configuration item for null references
pull/474/head
yx lin
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
4 additions and
1 deletions
-
aspnet-core/modules/dapr/LINGYUN.Abp.Dapr.Client/LINGYUN/Abp/Dapr/Client/DaprRemoteServiceConfigurationExtensions.cs
|
|
@ -17,8 +17,11 @@ public static class DaprRemoteServiceConfigurationExtensions |
|
|
return configuration.GetOrDefault(AppId) ?? throw new AbpException($"Could not get AppId for RemoteServices Configuration."); |
|
|
return configuration.GetOrDefault(AppId) ?? throw new AbpException($"Could not get AppId for RemoteServices Configuration."); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public static RemoteServiceConfiguration SetAppId([NotNull] this RemoteServiceConfiguration configuration, [CanBeNull] string value) |
|
|
public static RemoteServiceConfiguration SetAppId([NotNull] this RemoteServiceConfiguration configuration, [NotNull] string value) |
|
|
{ |
|
|
{ |
|
|
|
|
|
Check.NotNullOrEmpty(configuration, nameof(configuration)); |
|
|
|
|
|
Check.NotNullOrEmpty(value, nameof(value)); |
|
|
|
|
|
|
|
|
configuration[AppId] = value; |
|
|
configuration[AppId] = value; |
|
|
return configuration; |
|
|
return configuration; |
|
|
} |
|
|
} |
|
|
|