Avoid duplication on ban voting #61

Closed
opened 2024-03-20 10:50:46 +00:00 by d1msdale · 4 comments
d1msdale commented 2024-03-20 10:50:46 +00:00 (Migrated from github.com)

Sometime when you couple of times click for voting - your vote could be duplicated. Current logic doesn't check voter for unique. I added check for this. Also I have suspicious that should change checking from _id to id in all cases, because by mongo logic '_id' and 'id' are different fields an there could be potential collision

Like a proposition should change

from push to array to update

image

Sometime when you couple of times click for voting - your vote could be duplicated. Current logic doesn't check voter for unique. I added check for this. Also I have suspicious that should change checking from _id to id in all cases, because by mongo logic '_id' and 'id' are different fields an there could be potential collision Like a proposition should change from push to array to update ![image](https://github.com/backmeupplz/banofbot/assets/147830664/323eaf49-463e-4edd-8425-f290a32f9a0e)
backmeupplz commented 2024-03-25 18:48:38 +00:00 (Migrated from github.com)

hah, that would be nice

hah, that would be nice
d1msdale commented 2024-04-07 09:25:53 +00:00 (Migrated from github.com)

@backmeupplz I can't create PR. I suppose because I'm not in contributor list.

@backmeupplz I can't create PR. I suppose because I'm not in contributor list.
backmeupplz commented 2024-04-17 17:03:18 +00:00 (Migrated from github.com)

@d1msdale you should be able to :) fork and then create a PR from your fork

@d1msdale you should be able to :) fork and then create a PR from your fork
backmeupplz commented 2026-10-22 17:31:22 +00:00 (Migrated from github.com)

Thank you for taking the time to report this, and sorry it sat without an answer for so long. I'm cleaning up old issues and closing this one because it has been inactive for a long time. If it still affects you, please open a new issue with the current details and I'll take a look.

Thank you for taking the time to report this, and sorry it sat without an answer for so long. I'm cleaning up old issues and closing this one because it has been inactive for a long time. If it still affects you, please open a new issue with the current details and I'll take a look.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
backmeupplz/banofbot#61
No description provided.