diff --git a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/DefaultGoogleBlobNameCalculator.cs b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/DefaultGoogleBlobNameCalculator.cs index 90a7e7e7c43..fec52b44d1c 100644 --- a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/DefaultGoogleBlobNameCalculator.cs +++ b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/DefaultGoogleBlobNameCalculator.cs @@ -3,7 +3,7 @@ namespace Volo.Abp.BlobStoring.Google; -public class DefaultGoogleBlobNameCalculator: IGoogleBlobNameCalculator, ITransientDependency +public class DefaultGoogleBlobNameCalculator : IGoogleBlobNameCalculator, ITransientDependency { protected ICurrentTenant CurrentTenant { get; } diff --git a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobContainerConfigurationExtensions.cs b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobContainerConfigurationExtensions.cs index b99fd3af6a4..3c0efd4c86b 100644 --- a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobContainerConfigurationExtensions.cs +++ b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobContainerConfigurationExtensions.cs @@ -12,12 +12,12 @@ public static GoogleBlobProviderConfiguration GetGoogleConfiguration( public static BlobContainerConfiguration UseGoogle( this BlobContainerConfiguration containerConfiguration, - Action azureConfigureAction) + Action googleConfigureAction) { containerConfiguration.ProviderType = typeof(GoogleBlobProvider); containerConfiguration.NamingNormalizers.TryAdd(); - azureConfigureAction(new GoogleBlobProviderConfiguration(containerConfiguration)); + googleConfigureAction(new GoogleBlobProviderConfiguration(containerConfiguration)); return containerConfiguration; } diff --git a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobNamingNormalizer.cs b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobNamingNormalizer.cs index 68f4318acb3..8dc840d8052 100644 --- a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobNamingNormalizer.cs +++ b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobNamingNormalizer.cs @@ -5,7 +5,7 @@ namespace Volo.Abp.BlobStoring.Google; -public class GoogleBlobNamingNormalizer: IBlobNamingNormalizer, ITransientDependency +public class GoogleBlobNamingNormalizer : IBlobNamingNormalizer, ITransientDependency { /// /// https://cloud.google.com/storage/docs/buckets#naming @@ -83,7 +83,7 @@ protected virtual string RemoveInvalidStartEndCharacters(string containerName) if (!char.IsLetterOrDigit(containerName[0])) { containerName = containerName.Substring(1); - return RemoveInvalidStartEndCharacters( containerName); + return RemoveInvalidStartEndCharacters(containerName); } if (!char.IsLetterOrDigit(containerName[containerName.Length - 1])) diff --git a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobProvider.cs b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobProvider.cs index dc5eefc1ee4..6f9b5c280e4 100644 --- a/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobProvider.cs +++ b/framework/src/Volo.Abp.BlobStoring.Google/Volo/Abp/BlobStoring/Google/GoogleBlobProvider.cs @@ -27,7 +27,7 @@ public async override Task SaveAsync(BlobProviderSaveArgs args) var blobName = GoogleBlobNameCalculator.Calculate(args); var containerName = GetContainerName(args); - if(await BlobExistsAsync(args, blobName) && !args.OverrideExisting) + if (await BlobExistsAsync(args, blobName) && !args.OverrideExisting) { throw new BlobAlreadyExistsException($"Saving BLOB '{args.BlobName}' does already exists in the container '{GetContainerName(args)}'! Set {nameof(args.OverrideExisting)} if it should be overwritten."); } @@ -54,7 +54,6 @@ public async override Task DeleteAsync(BlobProviderDeleteArgs args) { return true; } - return true; } diff --git a/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/AbpBlobStoringGoogleTestModule.cs b/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/AbpBlobStoringGoogleTestModule.cs index cca775a04fb..be2de91a389 100644 --- a/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/AbpBlobStoringGoogleTestModule.cs +++ b/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/AbpBlobStoringGoogleTestModule.cs @@ -10,7 +10,7 @@ namespace Volo.Abp.BlobStoring.Google; /// -/// This module will not try to connect to azure. +/// This module will not try to connect to Google Cloud Storage. /// [DependsOn( typeof(AbpBlobStoringGoogleModule), diff --git a/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/GoogleBlobNameCalculator_Tests.cs b/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/GoogleBlobNameCalculator_Tests.cs index dbdc95c6f4a..781900ad81a 100644 --- a/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/GoogleBlobNameCalculator_Tests.cs +++ b/framework/test/Volo.Abp.BlobStoring.Google.Tests/Volo/Abp/BlobStoring/Google/GoogleBlobNameCalculator_Tests.cs @@ -10,8 +10,8 @@ public class GoogleBlobNameCalculator_Tests : AbpBlobStoringGoogleTestCommonBase private readonly IGoogleBlobNameCalculator _calculator; private readonly ICurrentTenant _currentTenant; - private const string AzureContainerName = "/"; - private const string AzureSeparator = "/"; + private const string GoogleContainerName = "/"; + private const string GoogleSeparator = "/"; public GoogleBlobNameCalculator_Tests() { @@ -24,7 +24,7 @@ public void Default_Settings() { _calculator.Calculate( GetArgs("my-container", "my-blob") - ).ShouldBe($"host{AzureSeparator}my-blob"); + ).ShouldBe($"host{GoogleSeparator}my-blob"); } [Fact] @@ -36,7 +36,7 @@ public void Default_Settings_With_TenantId() { _calculator.Calculate( GetArgs("my-container", "my-blob") - ).ShouldBe($"tenants{AzureSeparator}{tenantId:D}{AzureSeparator}my-blob"); + ).ShouldBe($"tenants{GoogleSeparator}{tenantId:D}{GoogleSeparator}my-blob"); } }