🐛 Fixed theme editor launch gate for allowlisted themes on limited plans#27970
Conversation
- the server's POST /themes/upload/ blocks every save by a limited customer using a `.` sentinel that's never in the allowlist, so editing any theme on a plan with customThemes enabled is rejected regardless of which theme is active - the launch gate previously checked the active theme name against the allowlist, so customers whose current theme happened to be allowlisted could enter the editor only to hit a generic "something went wrong" toast on save - the gate at all three editor entry points (Change theme menu, installed themes list, /theme/edit/:name deep link) now uses the same `.` sentinel as the upload endpoint, so the LimitModal fires at launch with the host's customThemes error message instead
WalkthroughThis PR unifies the theme editor access control by consolidating how three components check editor limits. Previously, the logic conditionally passed either the Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
POST /themes/upload/blocks every save by a limited customer using a.sentinel that's never in the allowlist, so editing any theme on a plan with acustomThemeslimit enabled is rejected regardless of which theme is active/theme/edit/:namedeep link) now uses the same.sentinel as the upload endpoint, so the LimitModal fires at launch with the host's customThemes error message insteadGot some code for us? Awesome 🎊!
Please take a minute to explain the change you're making:
Please check your PR against these items:
We appreciate your contribution! 🙏