Points not being awarded in Poll.OnVote automation

I'm trying to create a new Automation rule to award points to a user who votes in a poll but I can't get the points to be awarded. Debugging the code shows that all the values are correct in the award point function, but still no points. 

var userId = context_v2_automationTrigger.Arguments.VotingUserId;
var contentId = context_v2_automationTrigger.Arguments.ContentId;
var contentTypeId = context_v2_automationTrigger.Arguments.ContentTypeId;

if (context_v2_automationTrigger.Event == 'OnVote') {
    core_v2_eventLog.Write("TRIGGER Poll.OnVote", { Category: 'element14 AR', EventId: -1, EventType: 'Information' });
    context_v1_pointsAutomation.AwardPoints(userId, contentId, contentTypeId);
}
core_v2_eventLog.Write("Poll Status: " + context_v2_automationTrigger.Event + " - UserId: " + userId + " - contentId: " + contentId + " - contentTypeId: " + contentTypeId, { Category: 'element14 AR', EventId: -1, EventType: 'Information' });

Member Point rule is setup to use this automation:

Parents
No Data
Reply
  • Had QA help me with testing this more thoroughly and it seems to be an issue with the polls that have been migrated versus newly created polls. The migrated ones don't award the points but the newly created ones do. Not sure if that's a Telligent issue or some weirdness from our migration process.

    I checked the result from context_v1_pointsAutomation.AwardPoints and there are never any errors in there (and never anything in the Exceptions log). There will just be a warning if you vote twice in the same poll.

Children