Skip to content

📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!

Limit feedbacks to 5 per hour per user

Blue Mouse0a94359b2388
diff --git a/backend/apps/cloud/src/user/user.controller.ts b/backend/apps/cloud/src/user/user.controller.ts
index bacb3b1d4..db1f4492c 100644
--- a/backend/apps/cloud/src/user/user.controller.ts
+++ b/backend/apps/cloud/src/user/user.controller.ts
@@ -246,6 +246,9 @@ export class UserController {
const ip = getIPFromHeaders(headers) || requestIp || ''
const userAgent = headers['user-agent'] || ''
+
+ await checkRateLimit(userId, 'user-feedback', 5, 3600)
+
const message = body.message.trim()
if (!message) {