Skip to content

Commit

Permalink
human readable date
Browse files Browse the repository at this point in the history
  • Loading branch information
pheisiph committed May 2, 2011
1 parent 2a06153 commit 8306b64
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/views/users/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@
<ul class="daily">
<% for day in @posts_by_days do %>
<li>
<p><%= day[0] %></p>
<% days_ago = Time.now.to_date - day[0]%>
<p><%= days_ago == 0 ? "Today" : "#{days_ago} #{pluralize(2, 'day')} ago" %></p>
<ul class="taskly">
<% for post in day[1] do %>
<li>
Expand Down

0 comments on commit 8306b64

Please sign in to comment.