<div dir="ltr">I think that is the supposed behaviour... Being true, it executes what you tell it to do and continues to the next priority.<div><br></div><div>I would suggest you to try using gotoif instead, maybe it helps controlling the flow easily. Something like:</div><div><br></div><div><pre style="background-image:initial;background-position:0px 0px;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;box-sizing:border-box;margin-top:0px;margin-bottom:0px;padding:0px;border:0px;outline:0px;font-size:14px;vertical-align:baseline;color:rgb(65,65,65)"><code style="box-sizing:border-box;margin:0px;padding:0px;border:0px;outline:0px;vertical-align:baseline;background:0px 0px">  same => n, Verbose(callerid 0:1 is ${CALLERID(num):0:1})</code></pre><pre style="background-image:initial;background-position:0px 0px;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;box-sizing:border-box;margin-top:0px;margin-bottom:0px;padding:0px;border:0px;outline:0px;font-size:14px;vertical-align:baseline;color:rgb(65,65,65)"><code style="box-sizing:border-box;margin:0px;padding:0px;border:0px;outline:0px;vertical-align:baseline;background:0px 0px">  sam<font face="monospace, monospace">e => n, GotoIf(</font></code><font face="monospace, monospace">$["${CALLERID(num):0:<span style="font-size:small;color:rgb(34,34,34)">1}" = "+"]?remove:send)</span></font></pre></div><div><font face="monospace, monospace">  <span style="background-color:initial;color:rgb(65,65,65);font-size:14px">sam</span><font style="background-color:initial;color:rgb(65,65,65);font-size:14px">e => n(remove),</font>Set(CALLERID(num) = ${CALLERID(num):1})</font></div><div><font face="monospace, monospace"><font style="background-color:initial;color:rgb(65,65,65);font-size:14px">  same => n(send),Verbose(called number is </font></font><span style="color:rgb(65,65,65);font-size:14px"><font face="monospace, monospace">${CALLERID(num))</font></span></div><div><font face="monospace, monospace"><span style="color:rgb(65,65,65);font-size:14px">  same => n</span>,GotoIf(${BLACKLIST()}?make-em-wait)</font></div><div><font face="monospace, monospace"><br></font></div><div><pre style="box-sizing:border-box;margin-top:0px;margin-bottom:0px;padding:0px;border:0px;outline:0px;font-size:14px;vertical-align:baseline;background-image:initial;background-position:0px 0px;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;color:rgb(65,65,65)"><br></pre></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Feb 14, 2019 at 12:06 AM sean darcy <<a href="mailto:seandarcy2@gmail.com">seandarcy2@gmail.com</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 2/13/19 6:22 PM, Dovid Bender wrote:<br>
> Try == in your gotoif (instead of =)<br>
> <br>
> <br>
> <br>
> <br>
> Regards,<br>
> <br>
> Dovid<br>
> <br>
> <br>
> <br>
>         Original Message<br>
> <br>
> <br>
> <br>
> From: <a href="mailto:seandarcy2@gmail.com" target="_blank">seandarcy2@gmail.com</a><br>
> Sent: February 14, 2019 01:14<br>
> To: <a href="mailto:asterisk-users@lists.digium.com" target="_blank">asterisk-users@lists.digium.com</a><br>
> Reply-to: <a href="mailto:asterisk-users@lists.digium.com" target="_blank">asterisk-users@lists.digium.com</a><br>
> Subject: [asterisk-users] trouble removing + sign<br>
> <br>
> <br>
> I'm using BLACKLIST() to check numbers, which does not like leading +<br>
> signs. I want to test if there is a plus sign, and then remove it.<br>
> <br>
> I tried:<br>
> <br>
>    ;  strip leading plus sign<br>
>     same => n, Verbose( callerid 0:1 is ${CALLERID(num):0:1} )<br>
>     same => n,ExecIf($["${CALLERID(num):0:1}" = "+"]?Set(CALLERID(num) =<br>
> ${CALLERID(num):1})<br>
>     same=>n,GotoIf(${BLACKLIST()}?make-em-wait)<br>
> <br>
> but it's stripping the first character + sign or not. The callerid is<br>
> 1203XXYYYY<br>
> <br>
>       -- Executing [s@hangup-spam:3] Verbose("PJSIP/2667075-0000000b", "<br>
> callerid 0:1 is 1 ") in new stack<br>
>    callerid 0:1 is 1<br>
>       -- Executing [s@hangup-spam:4] ExecIf("PJSIP/2667075-0000000b",<br>
> "0?Set(CALLERID(num) = 203XXXYYYY") in new stack<br>
>       -- Executing [s@hangup-spam:5] GotoIf("PJSIP/2667075-0000000b",<br>
> "0?make-em-wait") in new stack<br>
> <br>
> ExecIf correctly finds the comparison false(the "0"), but still executes<br>
> the appiftrue .<br>
> <br>
> What am I missing ?<br>
> <br>
> <br>
> --<br>
<br>
Tried the double equal sign. Same result.<br>
<br>
sean<br>
<br>
<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>