洪 民憙 (Hong Minhee)'s avatar
洪 民憙 (Hong Minhee)

@hongminhee@hollo.social

Hello @MastodonEngineering,

I wanted to share some feedback on the documentation provided in the Highlighting Journalism on Mastodon blog post.

Specifically, in The technical section, the example code for the fediverse:creator meta tag is given as:

<meta name="fediverse:creator" content="@Gargron@mastodon.social" />

Based on my testing (and that of others), Mastodon doesn't seem to recognize the creator link correctly when the leading @ is present in the content attribute. It only works when the @ is removed, like this:

<meta name="fediverse:creator" content="Gargron@mastodon.social" />

Following the blog's example directly led to some wasted time figuring out why it wasn't working. It would be great if either the example in the blog post could be corrected to reflect the current requirement, or if Mastodon's parser could be made more flexible to accept the handle with or without the leading @.

Appreciate all you do for !

wakest ⁂'s avatar
wakest ⁂

@liaizon@social.wake.st · Reply to 洪 民憙 (Hong Minhee)'s post

@hongminhee @MastodonEngineering supporting both with and without the `@` seems most sensible to me, as there is continual confusion as to where exactly the `@` is needed and where it is not.

Julian Fietkau's avatar
Julian Fietkau

@julian@fietkau.social · Reply to 洪 民憙 (Hong Minhee)'s post

@hongminhee @MastodonEngineering I did a little bit of digging. The tag is read here and stored unchanged for later processing: github.com/mastodon/mastodon/b

It is then passed to the account resolver, still as an unchanged string: github.com/mastodon/mastodon/b

The account resolver calls its internal function "process_options" to parse the string, which is supposed to strip the leading "@" here: github.com/mastodon/mastodon/b

So it's correct that both variants should work the same. I wonder what's going wrong.