major change to override Write-Error func
This commit is contained in:
+2
-2
@@ -27,11 +27,11 @@ If ( $LFCLI ) {
|
||||
|
||||
If ( $DeleteAfterUpload ) {
|
||||
Try { Start-Process "${LFCLI}" -ArgumentList "filedrop /url:${FiledropURL} /from:""${From}"" /subject:""${Subject}"" /msg:""${Message}"" /c:n /deleteAfterUpload /f:""${FileToUpload}""" -Wait }
|
||||
Catch { LogErr $_.Exception.Message }
|
||||
Catch { Write-Error $_.Exception.Message }
|
||||
}
|
||||
Else {
|
||||
Try { Start-Process "${LFCLI}" -ArgumentList "filedrop /url:${FiledropURL} /from:""${From}"" /subject:""${Subject}"" /msg:""${Message}"" /c:n /f:""${FileToUpload}""" -Wait }
|
||||
Catch { LogErr $_.Exception.Message }
|
||||
Catch { Write-Error $_.Exception.Message }
|
||||
}
|
||||
}
|
||||
Else { Write-Output "The specified file does not exist: ""${FileToUpload}""" }
|
||||
|
||||
Reference in New Issue
Block a user