- Ya
- 5 Agosti 2026, 21:05 UTC
- Mwandishi
- Kamo
- Ahadi ya
- 39875ed
Three defects in how an organization's branding location is derived. my-networks named the full logo "logo-full." + logoFullExt, defaulting to "svg" when the column is unset. That is a hard 404 for any org whose full logo is a PNG uploaded before the column existed — BluEleven's logo-full.png was being advertised as logo-full.svg. An unset column now falls back to logo.svg, the one key the upload path always writes whatever the real format is, rather than guessing a filename that may not exist. The asset host was theme.<full hostname>. It has to be the registrable apex: a subdomain tenant's files live in its own bucket folder but are served from the parent apex's host, which is what kamo-internal's buildThemeBaseForFqdn already does. The two must agree or a logo is written under one key and read from another. Five call sites each picked the org's domain with findFirst() over Organization.getDomains(), a @OneToMany List with no @OrderBy, so "first" was whatever the database returned. Invisible only while every org has exactly one root domain — the top-level org has two active alias-less rows, kamocrm.com and localhost. localhost winning is not a different logo but no logo, since it has no registrable domain, and resolveParentRootDomain feeds child-subdomain provisioning, so it would have produced child.localhost. pickPreferredFqdn decides where logos are uploaded, so it could also disagree with the read path about which folder an org's logo lives in. Consolidated into OrgDomains, next to AvatarObjectPaths, which exists for the same reason: registrable hostnames only, which also stops an alias row's bare label ("api", "login") being handed over as an org's domain; apex before subdomain; alphabetical to break the remaining tie. Verified against prod that no org's theme folder moves — every org has a dotted root domain.