I uploaded a script that runs in the debugger, but...
# suitescript
e
I uploaded a script that runs in the debugger, but when I try to make a script record or edit this script I now get:
Fail to evaluate script: All SuiteScript API Modules are unavailable while executing your define callback.
z
Are you using modern JS with 2.X?
e
Yeah.. I think the error was a trailing comma
👍 1
Sometimes that seems to work and others it just fails
This works
Copy code
throw error.create({
        name: name,
        message: desc,
        notifyOff: true,
      });
This fails:
Copy code
return {
      post: autoClaimFulfillment,
    };
I still get
Fail to evaluate script
🤔 Any other modern JS ting my linter could have added @Zack?