Pleroma.Object/1: take %Object{} as argument instead
[akkoma] / lib / pleroma / web / templates / feed / feed / _tag_activity.atom.eex
index da4fa6d6c76109fa81f501f6f97bd7a621540fcd..8d78520cf56b52d1f653cee6dddd2e4ae8e7da9f 100644 (file)
@@ -1,12 +1,12 @@
 <entry>
     <activity:object-type>http://activitystrea.ms/schema/1.0/note</activity:object-type>
     <activity:verb>http://activitystrea.ms/schema/1.0/post</activity:verb>
-    
+
     <%= render @view_module, "_tag_author.atom", assigns %>
-    
+
     <id><%= @data["id"] %></id>
-    <title><%= activity_title(@object, Keyword.get(@feed_config, :post_title, %{})) %></title>
-    <content type="html"><%= activity_content(@object) %></content>
+    <title><%= activity_title(@data, Keyword.get(@feed_config, :post_title, %{})) %></title>
+    <content type="html"><%= activity_content(@data) %></content>
 
   <%= if @activity.local do %>
     <link type="application/atom+xml" href='<%= @data["id"] %>' rel="self"/>
@@ -15,8 +15,8 @@
     <link type="text/html" href='<%= @data["external_url"] %>' rel="alternate"/>
   <% end %>
 
-    <published><%= @data["published"] %></published>
-    <updated><%= @data["published"] %></updated>
+    <published><%= @activity.data["published"] %></published>
+    <updated><%= @activity.data["published"] %></updated>
 
     <ostatus:conversation ref="<%= activity_context(@activity) %>">
       <%= activity_context(@activity) %>
@@ -26,7 +26,7 @@
    <%= if @data["summary"] do %>
     <summary><%= @data["summary"] %></summary>
    <% end %>
-  
+
     <%= for id <- @activity.recipients do %>
       <%= if id == Pleroma.Constants.as_public() do %>
         <link rel="mentioned"
@@ -40,9 +40,9 @@
         <% end %>
       <% end %>
     <% end %>
-  
-    <%= for tag <- @data["tag"] || [] do %>
-      <category term="<%= tag %>"></category>
+
+    <%= for hashtag <- Object.hashtags(@object) do %>
+      <category term="<%= hashtag %>"></category>
     <% end %>
 
     <%= for {emoji, file} <- @data["emoji"] || %{} do %>