<div dir="ltr">gotoif accomplishes exactly what you want (except the one line part).<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Dec 23, 2021 at 3:32 PM Antony Stone <<a href="mailto:Antony.Stone@asterisk.open.source.it">Antony.Stone@asterisk.open.source.it</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Thursday 23 December 2021 at 18:31:38, <a href="mailto:asterisk@phreaknet.org" target="_blank">asterisk@phreaknet.org</a> wrote:<br>
<br>
> > -----Original Message-----<br>
> > From: asterisk-users <<a href="mailto:asterisk-users-bounces@lists.digium.com" target="_blank">asterisk-users-bounces@lists.digium.com</a>> On Behalf<br>
> > Of Dovid Bender<br>
> > Sent: Thursday, December 23, 2021 12:11 PM<br>
> > To: Asterisk Users Mailing List - Non-Commercial Discussion <asterisk-<br>
> > <a href="mailto:users@lists.digium.com" target="_blank">users@lists.digium.com</a>><br>
> > Subject: Re: [asterisk-users] Exec two commands with ExecIf<br>
> > <br>
> > Anyone know why this never made it into Asterisk?<br>
> <br>
> I believe it was deemed not to be of interest to the community.<br>
<br>
Assuming that the dates in that ticket refer to 2021 (I see only months and <br>
days, not years), I don't recall any discussion taking place with the <br>
community about it, so that seems to me like a surprising explanation.<br>
<br>
After all, if GotoIf(), ExecIf() and While() are "deemed to be of interest", <br>
and therefore exist, why would a simple If() be deemed not to be of interest?<br>
<br>
And, taking it from the other point of view, even if many people genuinely <br>
think "meh, I don't think I'd use this", then surely they just avoid using it, <br>
as I suspect the majority of people do with DumpChan() (for example, to take a <br>
pretty obscure, yet still available, command at random).<br>
<br>
In short, what's the drawback to making If() available for those who would use <br>
it?<br>
<br>
Personally, I would very much like to see an If() statement made available.<br>
<br>
<br>
Antony.<br>
<br>
-- <br>
Tinned food was developed for the British Navy in 1813.<br>
<br>
The tin opener was not invented until 1858.<br>
<br>
                                                   Please reply to the list;<br>
                                                         please *don't* CC me.<br>
<br>
-- <br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" rel="noreferrer" target="_blank">http://www.api-digital.com</a> --<br>
<br>
Check out the new Asterisk community forum at: <a href="https://community.asterisk.org/" rel="noreferrer" target="_blank">https://community.asterisk.org/</a><br>
<br>
New to Asterisk? Start here:<br>
      <a href="https://wiki.asterisk.org/wiki/display/AST/Getting+Started" rel="noreferrer" target="_blank">https://wiki.asterisk.org/wiki/display/AST/Getting+Started</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
   <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" rel="noreferrer" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a></blockquote></div>