If "Take away points on node delete" and Point Expiration are both enabled, and a node is deleted after the points have already been expired, the points are subtracted again, leading to a negative net point balance.
Not sure whether this is userpoints API or userpoints_basic, so I left it at userpoints_basic.
Comments
Comment #1
jredding commentedhhmm.. it does bring up an interesting point since these two actions are mutually exclusive.
I am going to go with the bug is in userpoints_basic since it probably should (upon deletion)
(a) check to see if the points are due to expire and if so expire them immediately
(b) check to see if the points have already been expired (if the points expire before the node has been deleted).
I don't really see an efficient method in the userpoints core to check to see if another module's point have been "reversed" somehow (such as removing points on a node delete)
Comment #2
jredding commentedI'm making the decision that this should be coded into userpoints nodes and comments. It would extremely difficult for the core API to manage what other modules are doing.
If this is method turns out to be a major problem we can place a disclaimer on the expiration settings of the API stating that it will reverse point entries without consulting other modules (i.e. if another module already reversed the entry then two reversals will occur). It will be up to the admin to plan accordingly.