Skip to content

Commit

Permalink
Merge pull request #10 from Readify/shouldprocess
Browse files Browse the repository at this point in the history
Added missing call to `ShouldProcess` in `Merge-ZendeskTicket`
  • Loading branch information
kjacobsen authored Feb 5, 2020
2 parents 2671d74 + d3c682e commit 2ccd9df
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions functions/Merge-Ticket.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,9 @@ function Merge-Ticket {
source_comment = $SourceTicketComment
}

$result = Invoke-Method -Context $Context -Method 'Post' -Path $path -Body $body -Verbose:$VerbosePreference
$result
if ($PSCmdlet.ShouldProcess("$SourceTicketId => $TargetTicketId", 'Merge tickets.')) {
$result = Invoke-Method -Context $Context -Method 'Post' -Path $path -Body $body -Verbose:$VerbosePreference
$result
}

}

0 comments on commit 2ccd9df

Please sign in to comment.