@PitaJ said in Plugin works in development but not in production:
@deiden26 without calling the callback, NodeBB had no idea when you've finished your task. So until you call that callback, the value is indeterminate.
Edit: you just need to add the callback parameter to your function, and then add it as an argument to the waterfall.
Are you suggesting that this line
plugin.awardReputation = function(postData)
should have a callback parameter, like this
plugin.awardReputation = function(postData, callback)
and that my waterfall should end in
That doesn't seem right to me, because the
awardReputation function is being called for the
action:post.save hook. This hook only provides postData and no callback.