Subtracting one value from another and returning result

Options

Hi,

I created this in an addon…

[{vote_type: upvote,suggestion_vote_vote_type: 1},{vote_type: downvote,suggestion_vote_vote_type: 2}]

Is there a way to add a value that subtracts downvote from upvote which would return something like

[{vote_type: total,suggestion_vote_vote_type: -1}]

Thank you,

Dave


Comments