<p></p>
<p>I guess the function was supposed to be called only for the initial INVITE, the one that creates the call.</p>
<p>Overall, I do not use that much the module to have an opinion of this is good to have or someone also wants to charge a call twice (e.g., incoming leg and outgoing leg). The initial developer of the module is not active lately in the project, maybe <a class="user-mention" data-hovercard-type="user" data-hovercard-url="/users/linuxmaniac/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/linuxmaniac">@linuxmaniac</a> can give his opinion as I saw some commits to this module from him rather recently.</p>
<p>As a further remark, the protection could be good, but if there are cases to charge a call many times, then it should be made a modparam to control the behaviour.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/pull/2383#issuecomment-651865050">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABO7UZIWDF4JYMDZEZNVGX3RZH7SZANCNFSM4OMKISIA">unsubscribe</a>.<img src="https://github.com/notifications/beacon/ABO7UZJ7ZD6JN7DWHREGHI3RZH7SZA5CNFSM4OMKISIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOE3NKXWQ.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/kamailio/kamailio/pull/2383#issuecomment-651865050",
"url": "https://github.com/kamailio/kamailio/pull/2383#issuecomment-651865050",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>