Commits

Christian Specht committed df27a55

concatenate paths with Join-Path

  • Participants
  • Parent commits d3820d0

Comments (0)

Files changed (2)

 	break
 }
 
-$usbfolder = $usbdrive + "Backup_NAS"
+$usbfolder = Join-Path $usbdrive "Backup_NAS"
 
 "##########################################################"
 "#"
 }
 
 $nasdrive = $config.copy.nasdrive.value
-$nasfolder = $nasdrive + $config.copy.nasfolder.value
+$nasfolder = Join-Path $nasdrive $config.copy.nasfolder.value
 $waittime = $config.copy.waittime.value
 
 Import-LocalizedData -BindingVariable msg -FileName messages.psd1
 foreach ($node in $config.copy.sourcefolder)
 {
     $from = $node.from
-    $to = $nasfolder + $node.to   
+    $to = Join-Path $nasfolder $node.to   
     robocopy.exe "$from" "$to" *.* /mir /xj /fft
 }