mirror of
https://github.com/aljazceru/landscape-template.git
synced 2026-01-17 21:34:23 +01:00
Fix voting count
votes_count needs to be summed up
This commit is contained in:
@@ -206,7 +206,7 @@ module.exports = {
|
||||
await context.prisma.project.update({
|
||||
where: { id: project.id },
|
||||
data: {
|
||||
votes_count: (project.votes_count = vote.amount_in_sat),
|
||||
votes_count: project.votes_count + vote.amount_in_sat,
|
||||
},
|
||||
});
|
||||
// return the current vote
|
||||
|
||||
Reference in New Issue
Block a user