- Ya
- 26 Agosti 2026, 19:28 UTC
- Mwandishi
- kamo
- Ahadi ya
- 9fddde0
The theme base was built from a hostname: drop the leading label, join the rest with dashes, and that is the bucket folder. It answered correctly while every organization had a host of its own. On internal.kamocrm.com — which now serves every organization that has no domain — it answers "the platform", so those organizations were painted in Kamo's logo and colours with their own branding provisioned and unreferenced. The folder is the organization's ALIAS. Every organization has one; a domain is optional. getThemePath() takes a slug and nothing else, and the slug reaches it three ways, in order of how early they are known: - app/layout.tsx passes organization.alias into DynamicMetaLoader from the SERVER render, so the very first theme fetch names the right tenant rather than depending on where OrgProvider sits in the tree relative to that effect. - OrgProvider records it during render, for everything that paints on first commit. - A caller can name another organization outright — /network lists every organization in the network and renders a logo for each, and orgLogoSrc took a DOMAIN, so the ones without a domain of their own resolved to no theme origin at all and fell back to an initial with their logo sitting in the bucket. The host half of the URL follows the address being browsed, unchanged: MinIO serves the whole bucket from every theme.<apex> name, so it decides only whether the request resolves — never whose assets come back. That is what lets an organization be entered before its own domain does. The create wizard now waits on, and opens, the folder the SERVER named. It derived the folder from the org's domain and got it wrong twice: GET /org/{id} answers with the entity, whose `domains` is LAZY and serializes as null outside a transaction, so the derivation fell through to "{alias}.kamocrm.com". For Panda Express that meant polling panda-express-kamocrm-com while the theme had been written to pandaexpress-com — 45 seconds of waiting on a folder that would never exist, then opening the workspace under a host that resolves to nothing. Also here, and part of the same story: - The alias field refuses a label the platform keeps for itself while it is being typed, matching SecurityService's OrgAliasPolicy. "theme" would answer at the host every tenant reads its assets from, and "default" is the base theme every new organization is seeded from. - error.tsx and not-found.tsx had their own copy of the derivation, building **************** — a scheme the bucket does not serve. The watermark on those screens was a 404 for every organization. - The dead **************** helpers behind that scheme are gone rather than left for the next caller. 253 test files, 3396 tests. The i18n key guard verified against a fresh clone of the dictionary, the way CI resolves it.