Add type to rel=self link in feed.

This commit is contained in:
Roger Braun 2017-05-01 18:40:36 +02:00
parent e88062494e
commit ceb2f68432
2 changed files with 2 additions and 2 deletions

View File

@ -26,7 +26,7 @@ def to_simple_form(user, activities, users) do
{:updated, h.(most_recent_update)},
{:link, [rel: 'hub', href: h.(OStatus.pubsub_path(user))], []},
{:link, [rel: 'salmon', href: h.(OStatus.salmon_path(user))], []},
{:link, [rel: 'self', href: h.(OStatus.feed_path(user))], []},
{:link, [rel: 'self', href: h.(OStatus.feed_path(user)), type: 'application/atom+xml'], []},
{:author, UserRepresenter.to_simple_form(user)},
] ++ entries
}]

View File

@ -28,7 +28,7 @@ test "returns a feed of the last 20 items of the user" do
<updated>#{most_recent_update}</updated>
<link rel="hub" href="#{OStatus.pubsub_path(user)}" />
<link rel="salmon" href="#{OStatus.salmon_path(user)}" />
<link rel="self" href="#{OStatus.feed_path(user)}" />
<link rel="self" href="#{OStatus.feed_path(user)}" type="application/atom+xml" />
<author>
#{user_xml}
</author>