granary
granary copied to clipboard
refactor _create methods
they're all kinda monsters right now, and pretty similar across all the silos that support publish, both of which are signs that we should refactor them and break them up.
lightly discussed with @kylewm in IRC. not urgent, obviously.
Working on Twitter._create() right now, really feeling the need for this. So much of the logic for interpreting input AS1 objects and deciding what to publish is duplicated, badly, across the silos. https://github.com/snarfed/bridgy/issues/1045 is a perfect example of a bug caused by that duplication: we updated Mastodon to support bookmarks, and that update should have been shared across silos, but wasn't. Sigh.