Strange error in backend module

A backend function does not get called from main program, no errors, nothing. Just doesn´t work. When I click the Edit Web Module Permissions- option, I get:

" There is an error on line 4. After you fix the error, reopen the panel to edit the permissions. "

And this is line 4:

export async function fnVerifyReCaptcha(gToken, strIpAddress) {

In editor, no warnings or errors, in console window same. I don´t see the error.

Anyone does?

can you please share the url of your site’s page?

Hi Shlomi, thanks. Here it is:

I tried changing the function name and param names (maybe strIpAddress is read as stripaddress by some safety mechanism [had something like this before with function name sleep]), but error stays the same: error on line 4 (if you try to edit web module permissions in recaptcha.jsw)

EDIT: I now see that all my backend files have the same error when they start with:

export async function … (){

Hi,

i also see you are using async await on
export async function btnSubmit_click(event, $w) {

please try to remove it from first level of functions - both those which serves as element events, and those which are used as first level of backend functions (in jsw and called by front end). you can leave async await if top level backend function is invoking another javascript function internally

please share it works out for you,
shlomi

Shlomi, I kindly thank you for your quick reply. Thing is, I have to keep the async in both btnSubmit AND backend function, other wise the await´s in both btnSubmit (calling the backend fucntion) and fetch (inside backend function) start to throw errors.
Anyway, got it working as it is, basic problem was “console.log´s” in backend functions, which work sometimes (as in backend function email.jsw) and sometimes not (here).
Enjoy what´s left of the Sunday.