Jacksuyu commited on
Commit
d989816
·
1 Parent(s): ef31111

Raise idea submission rate limit to 20/hour for testing

Browse files
app/api/ideas/route.ts CHANGED
@@ -18,7 +18,7 @@ const createIdeaSchema = z.object({
18
  show_name: z.boolean().optional().default(false),
19
  });
20
 
21
- const RATE_LIMIT_PER_HOUR = 5;
22
 
23
  async function checkRateLimit(rateKey: string, ipAddress: string): Promise<boolean> {
24
  const now = new Date();
 
18
  show_name: z.boolean().optional().default(false),
19
  });
20
 
21
+ const RATE_LIMIT_PER_HOUR = 20;
22
 
23
  async function checkRateLimit(rateKey: string, ipAddress: string): Promise<boolean> {
24
  const now = new Date();
components/SubmitForm.tsx CHANGED
@@ -152,7 +152,7 @@ export function SubmitForm({ canShowIdentity }: { canShowIdentity: boolean }) {
152
  "Generate Requirements"
153
  )}
154
  </button>
155
- <p className="subtle text-xs">Rate-limited to 5 submissions/hour per anonymous identity and IP.</p>
156
  </div>
157
 
158
  {error ? <p className="rounded-lg border border-red-200 bg-red-50 p-3 text-sm text-red-700">{error}</p> : null}
 
152
  "Generate Requirements"
153
  )}
154
  </button>
155
+ <p className="subtle text-xs">Rate-limited to 20 submissions/hour per anonymous identity and IP.</p>
156
  </div>
157
 
158
  {error ? <p className="rounded-lg border border-red-200 bg-red-50 p-3 text-sm text-red-700">{error}</p> : null}