Add-DeprecationWarning-obj$result-message"The 'restart' parameter causes instability. Use the 'win_reboot' action conditionally on 'reboot_required' return value instead"-version2.6
Add-DeprecationWarning-obj$result-message"the use of name has been deprecated, please remove from the task options"-version2.6
}
# validate initial arguments, more is done after analysing the exec path
if($expected_return_code-eq""){
Add-DeprecationWarning-obj$result-message"an empty string for expected_return_code will be deprecated in the future, omit the value or set it explicitly if you wish to override it"-version2.6
$expected_return_code=@(0,3010)
}
$valid_return_codes=@()
foreach($rcin($expected_return_code)){
try{
@ -373,7 +363,7 @@ if ($state -eq "absent") {
}
$result.rc=$process_result.rc
$result.exit_code=$process_result.rc# deprecate in 2.6
$result.exit_code=$process_result.rc# deprecate in 2.8