Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User counters / actual clues fix #6276

Merged
merged 2 commits into from
Dec 31, 2024
Merged

User counters / actual clues fix #6276

merged 2 commits into from
Dec 31, 2024

Conversation

gc
Copy link
Collaborator

@gc gc commented Dec 31, 2024

Description:

Changes:

Other checks:

  • I have tested all my changes thoroughly.

@github-actions github-actions bot added the BSO Bot School Old label Dec 31, 2024
value Decimal @db.Decimal(13, 3)

@@id([user_id, key])
@@unique([user_id, key])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The @@unique([user_id, key]) is redundant because @@id([user_id, key]) already ensures uniqueness for the combination of user_id and key. Consider removing the @@unique constraint.

@@ -0,0 +1,23 @@
export async function incrementUserCounter(_userID: string, _key: string, incrementUserCounter: number) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The parameter incrementUserCounter should be renamed to something more descriptive like incrementValue to avoid confusion with the function name.

@gc gc merged commit 6b1edf6 into bso Dec 31, 2024
4 checks passed
@gc gc deleted the user_counters_clue_fix branch December 31, 2024 07:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BSO Bot School Old
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant