Any way to debug cloud code faster?

I know that the error is somewhere between lines 1000 and 1100, but this is the error I’m getting in the log:

2021-12-19T13:27:32.389Z - SyntaxError: Unexpected identifier
    at customUserPlugin (/moralis-server/cloud/main.js:108:26)
    at /moralis-server/lib/cloud-code/plugins/index.js:70:15
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async Object.initialize (/moralis-server/lib/cloud-code/plugins/index.js:59:3)

It’s not pointing me to any specific line in my cloud functions file. Is there any way to check where exactly is the error?

You could copy all the code in an editor with syntax highlighting.

1 Like