fix: Fix stripe_service postgres RealDictCursor row access

This commit is contained in:
Your Name
2026-03-31 22:36:48 +02:00
parent dac23667df
commit d4236b0757

View File

@@ -58,12 +58,12 @@ def _ensure_stripe_columns():
"SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'users')"
)
row = cursor.fetchone()
if not row or not row[0]:
if not row or not row.get("exists"):
return
cursor.execute(
"SELECT column_name FROM information_schema.columns WHERE table_name = 'users'"
)
cols = [row[0] for row in cursor.fetchall()]
cols = [row["column_name"] for row in cursor.fetchall()]
else:
table_exists = conn.execute(
"SELECT name FROM sqlite_master WHERE type='table' AND name='users'"