Generate prayer ID on server to fix crypto.randomUUID browser compat

Older browsers (and non-HTTPS contexts) don't have crypto.randomUUID.
Move ID generation to the server using Node's built-in crypto module.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DReRqHxSYuVfCzTzQGD9hZ
This commit is contained in:
Claude committed 2026-07-18 17:18:12 +00:00
1 parent a27b35191d
commit bdf27b8b99
2 files changed
+3 -3

No files matched your search

+1 -2
View File
@@ -25,8 +25,7 @@ export function usePrayers() {
}, []);
const addPrayer = useCallback(async (request: string, tags: string[]) => {
const prayer: Prayer = {
id: crypto.randomUUID(),
const prayer = {
request,
answer: '',
status: 'active',