Skip to content

Commit

Permalink
Change default time zone of RSS for event calendar (publiclab#2279)
Browse files Browse the repository at this point in the history
  • Loading branch information
jywarren authored and SidharthBansal committed Feb 11, 2018
1 parent ef9da48 commit 5252974
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
11 changes: 1 addition & 10 deletions app/views/sidebar/_user.html.erb
Original file line number Diff line number Diff line change
@@ -1,24 +1,15 @@
<div class="col-md-3">

<%= render :partial => "sidebar/post_button" %>
<% if params[:controller] != 'questions' %>
<%= feature('sidebar-feature') %>
<% end %>

<div class="hidden-xs hidden-sm">
<p><i class="fa fa-envelope"></i> <a href="/lists"><%= t('sidebar._user.discussion_list') %> &raquo;</a></p>
<p><%= t('sidebar._user.work_happens_on_discussion_lists') %> <a href="/lists"><%= t('sidebar._user.join_one_today') %></a></p>
<!--<p><a href="/wiki/barnraising-2013"><img src="/images/barnraising-2013.png" width="100%" /></a></p>-->
<hr />
</div>
<% if params[:controller] == 'questions' %>
<%= render partial: 'tag/sorting' %>
<% end %>
<hr/>

<%= render partial: 'sidebar/wikis', locals: { wikis: @wikis, title: I18n.t('sidebar._user.recent_wiki_edits'), node: @node } %>

</div>
2 changes: 1 addition & 1 deletion app/views/tag/rss.rss.builder
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ xml.rss :version => '2.0', 'xmlns:atom' => 'http://www.w3.org/2005/Atom' do
xml.author author
if node.power_tag('date') != ''
begin
xml.pubDate DateTime.strptime(node.power_tag('date'), "%m-%d-%Y").rfc822
xml.pubDate DateTime.strptime(node.power_tag('date'), "%m-%d-%Y").in_time_zone("America/New_York").rfc822
rescue
xml.pubDate node.power_tag('date')
end
Expand Down

0 comments on commit 5252974

Please sign in to comment.