Skip to content

Commit 77068c2

Browse files
authored
ref(backend): Add limit (#337)
1 parent df51ef8 commit 77068c2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Model/Entity/User.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,11 @@ public function spendablePotato(): int
221221
])
222222
->first();
223223

224+
// @FIXME make this based on 90 days
225+
if ((int)$result->spent >= 500) {
226+
return 0;
227+
}
228+
224229
return $this->potatoReceived() - (int)$result->spent;
225230
}
226231

0 commit comments

Comments
 (0)