Skip to content

Commit

Permalink
fix: system.datetime error in Azure blob upload
Browse files Browse the repository at this point in the history
  • Loading branch information
tjgruber committed Jun 1, 2024
1 parent 59f3f55 commit 84bc50a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Private/Invoke-AzureStorageBlobUpload.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ function Invoke-AzureStorageBlobUpload {
$UTCDateTime = (Get-Date).ToUniversalTime()

# Determine the token expiration count as minutes
$TokenExpireMinutes = [System.Math]::Round(([datetime]$Global:AccessToken.ExpiresOn.ToUniversalTime().UtcDateTime - $UTCDateTime).TotalMinutes)
$TokenExpireMinutes = [System.Math]::Round(([datetime]$Global:AccessToken.ExpiresOn.ToUniversalTime() - $UTCDateTime).TotalMinutes)

# Determine if refresh of access token is required when expiration count is less than or equal to minimum age
if ($TokenExpireMinutes -le 10) {
Expand Down

0 comments on commit 84bc50a

Please sign in to comment.