Patch #27671 ยป use-reverse_each.diff
| app/views/activities/index.html.erb (working copy) | ||
|---|---|---|
| 2 | 2 | 
    <p class="subtitle"><%= l(:label_date_from_to, :start => format_date(@date_to - @days), :end => format_date(@date_to-1)) %></p>  | 
| 3 | 3 | |
| 4 | 4 | 
    <div id="activity">  | 
| 5 | 
    <% @events_by_day.keys.sort.reverse.each do |day| %>
   | 
|
| 5 | 
    <% @events_by_day.keys.sort.reverse_each do |day| %>
   | 
|
| 6 | 6 | 
    <h3><%= format_activity_day(day) %></h3>  | 
| 7 | 7 | 
    <dl>  | 
| 8 | 8 | 
    <% sort_activity_events(@events_by_day[day]).each do |e, in_group| -%>  | 
| app/views/my/blocks/_timelog.html.erb (working copy) | ||
|---|---|---|
| 37 | 37 | 
    <th><%= l(:field_hours) %></th>  | 
| 38 | 38 | 
    </tr></thead>  | 
| 39 | 39 | 
    <tbody>  | 
| 40 | 
    <% entries_by_day.keys.sort.reverse.each do |day| %>
   | 
|
| 40 | 
    <% entries_by_day.keys.sort.reverse_each do |day| %>
   | 
|
| 41 | 41 | 
    <tr class="odd">  | 
| 42 | 42 | 
    <td><strong><%= day == User.current.today ? l(:label_today).titleize : format_date(day) %></strong></td>  | 
| 43 | 43 | 
    <td colspan="2"></td>  | 
| app/views/users/show.html.erb (working copy) | ||
|---|---|---|
| 53 | 53 | 
    :from => @events_by_day.keys.first %></h3>  | 
| 54 | 54 | |
| 55 | 55 | 
    <div id="activity">  | 
| 56 | 
    <% @events_by_day.keys.sort.reverse.each do |day| %>
   | 
|
| 56 | 
    <% @events_by_day.keys.sort.reverse_each do |day| %>
   | 
|
| 57 | 57 | 
    <h4><%= format_activity_day(day) %></h4>  | 
| 58 | 58 | 
    <dl>  | 
| 59 | 59 | 
    <% @events_by_day[day].sort {|x,y| y.event_datetime <=> x.event_datetime }.each do |e| -%>
   | 
| app/views/wiki/date_index.html.erb (working copy) | ||
|---|---|---|
| 14 | 14 | 
    <p class="nodata"><%= l(:label_no_data) %></p>  | 
| 15 | 15 | 
    <% end %>  | 
| 16 | 16 | |
| 17 | 
    <% @pages_by_date.keys.sort.reverse.each do |date| %>
   | 
|
| 17 | 
    <% @pages_by_date.keys.sort.reverse_each do |date| %>
   | 
|
| 18 | 18 | 
    <h3><%= format_date(date) %></h3>  | 
| 19 | 19 | 
    <ul>  | 
| 20 | 20 | 
    <% @pages_by_date[date].each do |page| %>  | 
| lib/diff.rb (working copy) | ||
|---|---|---|
| 32 | 32 | 
    aelem = a[aindex]  | 
| 33 | 33 | 
    next unless bmatches.has_key? aelem  | 
| 34 | 34 | 
    k = nil  | 
| 35 | 
            bmatches[aelem].reverse.each { |bindex|
   | 
|
| 35 | 
            bmatches[aelem].reverse_each { |bindex|
   | 
|
| 36 | 36 | 
    if k && (thresh[k] > bindex) && (thresh[k-1] < bindex)  | 
| 37 | 37 | 
    thresh[k] = bindex  | 
| 38 | 38 | 
    else  | 
| lib/plugins/open_id_authentication/lib/open_id_authentication/db_store.rb (working copy) | ||
|---|---|---|
| 29 | 29 | 
    Association.find_all_by_server_url_and_handle(server_url, handle)  | 
| 30 | 30 | 
    end  | 
| 31 | 31 | |
| 32 | 
          assocs.reverse.each do |assoc|
   | 
|
| 32 | 
          assocs.reverse_each do |assoc|
   | 
|
| 33 | 33 | 
    a = assoc.from_record  | 
| 34 | 34 | 
    if a.expires_in == 0  | 
| 35 | 35 | 
    assoc.destroy  |