Closed machine-bit closed 2 months ago
Yeah so that's broken. Sorry. It's got the wrong parameter type. You can fix it locally by changing the type in the Remove-HaloTicketBatch
to Int64[]
instead of array[]
. I'll get it fixed tomorrow and we're overdue a release anyway!
oh, and change $Actions -is [Array]
to $Tickets -is [Array]
this one's a bad copypasta :-D
@homotechsual I did actually see that bit and wondered what it was doing, it all makes sense now. Thought it was me rather than the code :-)
Just released 1.21.0 which should fix this :-)
@homotechsual can lslightly further; Exception: Exception calling "ShouldProcess" with "2" argument(s): "A command that prompts the user failed because the host program or the command type does not support user interaction. The host was attempting to request confirmation with the following message: Are you sure you want to perform this action?
Is this because Remove-HaloTicket needs the -confirm:$false passing?
Yeah, it would. We use ShouldProcess
for confirmation in all the batch commandlets and all remove commandlets.
If you're doing noninteractive scripts you should always set $ConfirmPreference
to None
or High
I am struggling to get this working, as path of teh parameter -tickets I have tried every connotaion of array / object and it still fails stating "Remove-HaloTicketBatch requires an array of ticket ids to delete." Anyone used thsi recently? I have got round it using a foreach loop and the Remove-HaloTicket command, but I have a feeling it might be a bug