Skip to content

Commit

Permalink
Changed from alternate container to alternate account
Browse files Browse the repository at this point in the history
  • Loading branch information
Henning Normann committed Oct 25, 2024
1 parent a22efc4 commit 78d2fab
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/Storage/Repository/BlobRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,12 @@ private BlobContainerClient CreateContainerClient(string org, int? storageContai
string cacheKey = GetClientCacheKey(org, storageContainerNumber);
if (!_memoryCache.TryGetValue(cacheKey, out BlobContainerClient client))
{
string containerName = string.Format(_storageConfiguration.OrgStorageContainer, org);
string accountName = string.Format(_storageConfiguration.OrgStorageAccount, org);
string containerName = string.Format(_storageConfiguration.OrgStorageContainer, org)
+ (storageContainerNumber != null ? $"-{storageContainerNumber}" : null);
if (storageContainerNumber != null)
{
accountName = accountName.Substring(0, accountName.Length - 2) + ((int)storageContainerNumber).ToString("D2");
}

UriBuilder fullUri = new()
{
Expand Down

0 comments on commit 78d2fab

Please sign in to comment.