I am trying to query the user class to find a user whose objectId
I pass from my app to Cloud Code. I keep getting this error when I try to deploy my code to Parse:
Uncaught SyntaxError: Unexpected token ILLEGAL in main.js:4
Can someone let me know what I am doing wrong?
Parse.Cloud.define("followerCount", function(request, response) {
var userQuery = new Parse.Query(Parse.User);
userQuery.equalTo(“objectId”, request.params.objectId);
var query = new Parse.Query("Friends");
query.equalTo("toUser", userQuery);
query.count({
success: function(count) {
response.success(count);
},
error: function() {
response.error("count failed");
}
});
});
You're using the wrong kind of quotes here: “objectId”
.
Replace them with the correct quotes: "objectId"