Skip to content

fix(cms): use CORE_SYNC_ENABLED for data-snapshot trigger guard#634

Merged
tataihono merged 3 commits intomainfrom
fix/core-sync-env-detection
Apr 2, 2026
Merged

fix(cms): use CORE_SYNC_ENABLED for data-snapshot trigger guard#634
tataihono merged 3 commits intomainfrom
fix/core-sync-env-detection

Conversation

@tataihono
Copy link
Copy Markdown
Contributor

Summary

  • The data-snapshot trigger guard was still using NODE_ENV !== "production" which doesn't work on Railway. Switches to CORE_SYNC_ENABLED !== "true" to match the rest of the env detection.

Test plan

  • Verify data-snapshot trigger works on prod (returns 202, not 403)

🤖 Generated with Claude Code

tataihono and others added 3 commits April 2, 2026 00:52
…t UI

NODE_ENV is not reliably set to "production" on Railway. Switch to
CORE_SYNC_ENABLED which is the explicit production flag already used
by the cron system. Remove closeLabel from dev-mode alerts to hide
the non-functional X button and add padding underneath.

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
…, fix alert UI

- Switch production detection from NODE_ENV to CORE_SYNC_ENABLED which
  is the explicit production flag already used by the cron system
- Add created/updated/deleted/errors columns to core_sync_states table
  so row counts persist across server restarts
- Auto-migrate existing tables to add the new stats columns
- Remove closeLabel from dev-mode alerts to hide non-functional X button
  and add padding underneath

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
The trigger guard was still using NODE_ENV which isn't set to
"production" on Railway. Align with the rest of the env detection.

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
@tataihono tataihono enabled auto-merge (squash) April 2, 2026 01:28
@tataihono tataihono merged commit 4d59d27 into main Apr 2, 2026
8 checks passed
@tataihono tataihono deleted the fix/core-sync-env-detection branch April 2, 2026 01:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant