That might work, but it’s never a good idea to write your code against a specific implementation. Plus, it seems that in this case the Lemmy devs shot themselves in the foot: why allow to create two different types of actors with the same name?!
Comment on If a Lemmy user has the same name as a community, how can I tag the community on Mastodon?
Die4Ever@retrolemmy.com 5 weeks agoWhat if the community was the first entry in the results instead of the user? Maybe that’s more appropriate and might cause Mastodon to default to the community when there’s a conflict
rglullis@communick.news 5 weeks ago
Die4Ever@retrolemmy.com 5 weeks ago
I agree. Users shouldn’t be allowed to choose a name that already exists as a community. But it would be a shame if communities could not be created because a user with that name already exists.
rglullis@communick.news 5 weeks ago
I think this is yet-another reason to have a separation between users and communities at the instance/domain level.
Setting up a server should require one top-level domain and two subdomains:
https://myserver.com/would be for webfinger and the actual backend.https://groups.myserver.com/would be the subdomain for the AS2.Group actorshttps://people.myserver.com/would be the subdomain for the AS2.Person actor
nutomic@lemmy.ml 4 weeks ago
This would make instance creation too complicated.
nutomic@lemmy.ml 4 weeks ago
Its intentionally in this order because Mastodon prioritizes the last item (ie the community). If the order was changed, it would be impossible for Mastodon users to interact with a community where a user with the same name exists.