fix(cron): birthday notifications require 1+ year like adoptedAt
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
f6aa825ad1
commit
b0d6a4d7d1
1 file changed
+1
@@ -24,6 +24,7 @@ export async function GET(req: Request) {
|
||||
WHERE birthday IS NOT NULL
|
||||
AND EXTRACT(MONTH FROM birthday) = ${month}
|
||||
AND EXTRACT(DAY FROM birthday) = ${day}
|
||||
AND birthday <= NOW() - INTERVAL '1 year'
|
||||
`;
|
||||
|
||||
// Find all pets whose adoptedAt matches today and was at least 1 year ago
|
||||
|
||||
Reference in new issue
Block a user