[SR-Users] Re: Difference betwwen TM functions in KEMI

2024-07-17 Thread Alex Balashov via sr-users
Hello Duarte, I wonder if this is down to differences in JS vs. config script in how truthiness is evaluated in `if` statements. In JavaScript, if(...) evaluates to true if the returned value is a non-zero number (positive or negative). In Kamailio config script[1], in contrast, a value less

[SR-Users] Difference betwwen TM functions in KEMI

2024-07-17 Thread Duarte Rocha via sr-users
Hello all, I'm using Kamailio with native script and KEMI in Javascript. I noticed that functions from the TM module can have different results if I call them on KEMI or Native script. Is this intended behaviour? Don't they share the state? In order to test this i made the following code : K

[SR-Users] Re: Dns record not alone?

2024-07-17 Thread Ben Kaufman via sr-users
Hi, I had observed the same thing a few weeks ago and asked in the Matrix chat. Daniel indicated that the warnings are safe, and will be changed to debug level in the near future: On Wed, June 26th: 1. miconda: I pushed a commit to make them debug. I added the warnings when invastigated a

[SR-Users] Add a Header to CANCEL request

2024-07-17 Thread sadik.oualla.mohamed--- via sr-users
Hello all, I am facing an issue with Kamailio when trying to add custom headers to CANCEL requests. My current configuration adds the "Reason" header perfectly: ``` if(!is_present_hf("Reason")){ $var(cause_request) = 31; append_hf("Reason: Q.850;cause=$var(cause_request)\r\n", "CSeq");