Skip to content

Fix hashtag processing

Alain St-Denis requested to merge astdenis/fix-hashtag-processing into master

URLs with fragments found in the text were split as a URL without the fragment and a hashtag. The Content.models.get_and_linkify_tags method was reworked to better identify URL fragments (along with an update to federation's URL_PATTERN) as well as catch and linkify HTML <a> tags that didn't come with a Hashtag AP object (firefish is one platform that does this). Also, handle cases where a hashtag previous sibling is white space which were throwing a TypeError. Replaced split with a URL_PATTERN search.

Note: federation must be updated to the commit identified in requirements.

Merge request reports