Problem
PR #234 added contract_address filtering to all frontend and API queries, but missed the admin hide/unhide operations in src/app/api/admin/auth.ts (lines ~74-75):
await supabase.from("storylines").update({ hidden }).eq("storyline_id", id)
await supabase.from("plots").update({ hidden }).eq("id", id);
Without the filter, hiding storyline #5 would hide it across ALL contracts, not just the current one.
Fix
Add .eq("contract_address", STORY_FACTORY.toLowerCase()) to both update queries.
Files
src/app/api/admin/auth.ts
Acceptance Criteria
Problem
PR #234 added
contract_addressfiltering to all frontend and API queries, but missed the admin hide/unhide operations insrc/app/api/admin/auth.ts(lines ~74-75):Without the filter, hiding storyline #5 would hide it across ALL contracts, not just the current one.
Fix
Add
.eq("contract_address", STORY_FACTORY.toLowerCase())to both update queries.Files
src/app/api/admin/auth.tsAcceptance Criteria