➜ ~ curl -X PUT "https://api.cloudflare.com/client/v4/accounts/[censored]/workers/scripts/test" \
-H "Authorization: Bearer [censored]" \
-H "Content-Type: application/javascript" \
-H "CF-WORKER-MAIN-MODULE-PART: worker.js" \
--form "worker.js="
{
"result": null,
"success": false,
"errors": [
{
"code": 10021,
"message": "Uncaught SyntaxError: Invalid left-hand side expression in prefix operation\n at worker.js:1:24\n"
}
],
"messages": []
}
➜ ~ curl -X PUT "https://api.cloudflare.com/client/v4/accounts/[censored]/workers/scripts/test" \
-H "Authorization: Bearer [censored]" \
-H "Content-Type: application/javascript" \
-H "CF-WORKER-MAIN-MODULE-PART: worker.js" \
--form "worker.js="
{
"result": null,
"success": false,
"errors": [
{
"code": 10021,
"message": "Uncaught SyntaxError: Invalid left-hand side expression in prefix operation\n at worker.js:1:24\n"
}
],
"messages": []
}