]> cat aescling's git repositories - mastodon.git/commit
Add conversation model, <ostatus:conversation /> (#3016)
authorEugen Rochko <eugen@zeonfederated.com>
Fri, 12 May 2017 17:09:21 +0000 (19:09 +0200)
committerGitHub <noreply@github.com>
Fri, 12 May 2017 17:09:21 +0000 (19:09 +0200)
commit5abdc77c8060a62ecf2259a1e9d63e862b9f7be7
tree95b0a69d8943d6171ad19257af1655cd733fc245
parentb5a9c6b3d292abc7e47d8a6f830f6b5589c04862
Add conversation model, <ostatus:conversation /> (#3016)

* Add <ostatus:conversation /> tag to Atom input/output

Only uses ref attribute (not href) because href would be
the alternate link that's always included also.

Creates new conversation for every non-reply status. Carries
over conversation for every reply. Keeps remote URIs verbatim,
generates local URIs on the fly like the rest of them.

* Fix conversation migration

* More spec coverage for status before_create

* Prevent n+1 query when generating Atom with the new conversations

* Improve code style

* Remove redundant local variable
app/lib/atom_serializer.rb
app/models/conversation.rb [new file with mode: 0644]
app/models/status.rb
app/models/stream_entry.rb
app/services/process_feed_service.rb
db/migrate/20170506235850_create_conversations.rb [new file with mode: 0644]
db/migrate/20170507000211_add_conversation_id_to_statuses.rb [new file with mode: 0644]
db/schema.rb
spec/fabricators/conversation_fabricator.rb [new file with mode: 0644]
spec/models/conversation_spec.rb [new file with mode: 0644]
spec/models/status_spec.rb