comparison app/views/tweets/_tweet.atom.erb @ 211:e07f6ea17deb

Less xhtml more escaping It looks like some older tweets aren't quite escaped properly for xhtml. Example (assuming not deleted): https://twitter.com/aaaa/status/169688458900668416
author nanaya <me@nanaya.pro>
date Fri, 11 Dec 2020 03:31:25 +0900
parents 70e90ea4b870
children 7a773720d81f
comparison
equal deleted inserted replaced
210:4a94ed44142d 211:e07f6ea17deb
2 <id><%= atom_id "#{tweet.user.id}/#{tweet.id}" %></id> 2 <id><%= atom_id "#{tweet.user.id}/#{tweet.id}" %></id>
3 <published><%= tweet.created_at.xmlschema %></published> 3 <published><%= tweet.created_at.xmlschema %></published>
4 <updated><%= tweet.created_at.xmlschema %></updated> 4 <updated><%= tweet.created_at.xmlschema %></updated>
5 <link rel="alternate" type="text/html" href="<%= status_url(tweet) %>"/> 5 <link rel="alternate" type="text/html" href="<%= status_url(tweet) %>"/>
6 <title><%= truncate tweet.unescaped_text, :length => 30 %></title> 6 <title><%= truncate tweet.unescaped_text, :length => 30 %></title>
7 <content type="xhtml"> 7 <content type="html">
8 <div xmlns="http://www.w3.org/1999/xhtml"> 8 <%= render(:partial => "tweet", :formats => :html, :locals => { :tweet => tweet }).to_str %>
9 <%= render :partial => "tweet", :formats => :html, :locals => { :tweet => tweet } %>
10 </div>
11 </content> 9 </content>
12 <author> 10 <author>
13 <name><%= tweet.user.screen_name %></name> 11 <name><%= tweet.user.screen_name %></name>
14 </author> 12 </author>
15 </entry> 13 </entry>