Skip to content

Commit 945eabe

Browse files
Justin Torreclaude
authored andcommitted
chore: consolidate migrations into single free_limit_exceeded TEXT column
Removed the old BOOLEAN migration and updated the remaining migration to add the TEXT column directly. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 0961a7c commit 945eabe

File tree

2 files changed

+5
-14
lines changed

2 files changed

+5
-14
lines changed

supabase/migrations/20260107000000_add_free_limit_exceeded.sql

Lines changed: 0 additions & 6 deletions
This file was deleted.
Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
1-
-- Change free_limit_exceeded from BOOLEAN to TEXT (YYYY-MM format)
2-
-- This allows tracking which month the limit was exceeded
3-
-- NULL = not exceeded, "2026-01" = exceeded in January 2026
1+
-- Add free_limit_exceeded column to track which month the free tier limit was exceeded
2+
-- Stores month in YYYY-MM format (e.g., "2026-01" = exceeded in January 2026)
3+
-- NULL = not exceeded or under limit
4+
-- When set, request/response bodies are not stored for non-PTB requests
45

5-
-- Drop the old boolean column
6-
ALTER TABLE organization DROP COLUMN IF EXISTS free_limit_exceeded;
7-
8-
-- Add new text column for month tracking
96
ALTER TABLE organization
10-
ADD COLUMN free_limit_exceeded TEXT DEFAULT NULL;
7+
ADD COLUMN IF NOT EXISTS free_limit_exceeded TEXT DEFAULT NULL;

0 commit comments

Comments
 (0)