Skip to content

Commit

Permalink
add properties variable
Browse files Browse the repository at this point in the history
  • Loading branch information
TRybina132 committed Oct 20, 2023
1 parent c094d83 commit 292df32
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ManagedCode.Storage.Azure/BlobStream.cs
Expand Up @@ -37,7 +37,8 @@ public override long Length
{
get
{
var metadata = _pageBlob.GetProperties().Value.Metadata;
var properties = _pageBlob.GetProperties();
var metadata = properties.Value.Metadata;
if (metadata.TryGetValue(MetadataLengthKey, out var length))
{
if (long.TryParse(length, out var realLength))
Expand All @@ -46,7 +47,7 @@ public override long Length
}
}

var contentLenght = _pageBlob.GetProperties().Value.ContentLength;
var contentLenght = properties.Value.ContentLength;
SetLengthInternal(contentLenght);
return contentLenght;
}
Expand Down

0 comments on commit 292df32

Please sign in to comment.