Skip to content

Commit

Permalink
Fixed downloading of attachments.
Browse files Browse the repository at this point in the history
  • Loading branch information
trparky committed Sep 7, 2024
1 parent 8b9296d commit 596a46c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Export-Bitwarden.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
RootModule = 'Export-Bitwarden.psm1'

# Version number of this module.
ModuleVersion = '1.45'
ModuleVersion = '1.46'

# Supported PSEditions
# CompatiblePSEditions = @()
Expand Down
5 changes: 4 additions & 1 deletion Export-Bitwarden.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ function Export-Bitwarden { # Don't touch this line!
# == WARNING!!! DO NOT TOUCH ANYTHING BELOW THIS!!! ==
# ====================================================

$ver = "1.45"
$ver = "1.46"

Write-Host -ForegroundColor Green "========================================================================================"
Write-Host -ForegroundColor Green "== Bitwarden Vault Export Script v$ver =="
Expand Down Expand Up @@ -364,6 +364,9 @@ function Export-Bitwarden { # Don't touch this line!
foreach ($attachment in $item.attachments) {
$filePath = Join-Path $saveFolderAttachments $item.name

if ($IsWindows) { $filePath = $filePath + "\" }
else { $filePath = $filePath + "/" }

& $bwCliBinName get attachment "$($attachment.fileName)" --itemid $item.id --output $filePath
if ($IsWindows) { Write-Host "" }
}
Expand Down

0 comments on commit 596a46c

Please sign in to comment.