Skip to content

Commit 34b806b

Browse files
committed
#91 fix
1 parent e49b882 commit 34b806b

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

Storages/ManagedCode.Storage.Azure/AzureStorage.cs

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,8 +154,17 @@ protected override async Task<Result> CreateContainerInternalAsync(CancellationT
154154
await StorageClient.SetAccessPolicyAsync(StorageOptions.PublicAccessType, cancellationToken: cancellationToken);
155155
}
156156

157-
IsContainerCreated = await StorageClient.ExistsAsync(cancellationToken);
158-
;
157+
try
158+
{
159+
IsContainerCreated = await StorageClient.ExistsAsync(cancellationToken);
160+
}
161+
catch (RequestFailedException e)
162+
{
163+
logger.LogException(e);
164+
//probably we don't have permission to check if container exists
165+
IsContainerCreated = true;
166+
}
167+
159168

160169
return Result.Succeed();
161170
}

0 commit comments

Comments
 (0)