I'm running parse-server and trying to create a parse cloud code function. I started with this oversimplified example:
Parse.Cloud.define("createContent", function(request, response) {
response.error("not implemented");
});
I can call my function using the REST API with curl and get a JSON with an error message: {"code":141,"error":"response.error is not a function"}
(this is not the error message I expected). Upon further examination response
object turned out to be null
.
This is the respective section of the log:
error: Failed running cloud function createContent for user undefined with:
Input: {}
Error: {"code":141,"message":"response.error is not a function"} functionName=createContent, code=141, message=response.error is not a function, , user=undefined
error: response.error is not a function code=141, message=response.error is not a function