Only include reply webmentions on posts
This commit is contained in:
@@ -152,6 +152,9 @@ module Adamantium
|
|||||||
.exclude(Sequel.pg_jsonb_op(:syndication_sources).has_key?("instagram"))
|
.exclude(Sequel.pg_jsonb_op(:syndication_sources).has_key?("instagram"))
|
||||||
.published
|
.published
|
||||||
.combine(:tags, :webmentions)
|
.combine(:tags, :webmentions)
|
||||||
|
.node(:webmentions) { |webmention|
|
||||||
|
webmention.where(type: "reply")
|
||||||
|
}
|
||||||
.order(Sequel.desc(:published_at))
|
.order(Sequel.desc(:published_at))
|
||||||
.limit(limit)
|
.limit(limit)
|
||||||
.to_a
|
.to_a
|
||||||
@@ -217,6 +220,9 @@ module Adamantium
|
|||||||
posts
|
posts
|
||||||
.published
|
.published
|
||||||
.combine(:tags, :trips, :webmentions)
|
.combine(:tags, :trips, :webmentions)
|
||||||
|
.node(:webmentions) { |webmention|
|
||||||
|
webmention.where(type: "reply")
|
||||||
|
}
|
||||||
.where(slug: slug)
|
.where(slug: slug)
|
||||||
.one!
|
.one!
|
||||||
end
|
end
|
||||||
|
Reference in New Issue
Block a user