X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/2515c77276ef7a735b1f6c719789f72205d08214..4b4449f7249837c89f2e33109521bf8e29ef8292:/app/controllers/diary_entry_controller.rb diff --git a/app/controllers/diary_entry_controller.rb b/app/controllers/diary_entry_controller.rb index 5bd95775d..7f5f4fb3a 100644 --- a/app/controllers/diary_entry_controller.rb +++ b/app/controllers/diary_entry_controller.rb @@ -48,7 +48,7 @@ class DiaryEntryController < ApplicationController if current_user != @diary_entry.user redirect_to :action => "view", :id => params[:id] - elsif params[:diary_entry] && @diary_entry.update_attributes(entry_params) + elsif params[:diary_entry] && @diary_entry.update(entry_params) redirect_to :action => "view", :id => params[:id] end @@ -192,13 +192,13 @@ class DiaryEntryController < ApplicationController def hide entry = DiaryEntry.find(params[:id]) - entry.update_attributes(:visible => false) + entry.update(:visible => false) redirect_to :action => "list", :display_name => entry.user.display_name end def hidecomment comment = DiaryComment.find(params[:comment]) - comment.update_attributes(:visible => false) + comment.update(:visible => false) redirect_to :action => "view", :display_name => comment.diary_entry.user.display_name, :id => comment.diary_entry.id end