Commit a7adb70b1d4c84f9226d4c4d4f25d0aab45c99ea
Exists in
master
and in
29 other branches
Merge branch 'ai3217' into 'master'
Expire LocationBlock cache on profile's location change http://noosfero.org/Development/ActionItem3217 See merge request !259
Showing
1 changed file
with
1 additions
and
0 deletions
Show diff stats
app/controllers/my_profile/maps_controller.rb
@@ -16,6 +16,7 @@ class MapsController < MyProfileController | @@ -16,6 +16,7 @@ class MapsController < MyProfileController | ||
16 | 16 | ||
17 | Profile.transaction do | 17 | Profile.transaction do |
18 | if profile.update_attributes!(params[:profile_data]) | 18 | if profile.update_attributes!(params[:profile_data]) |
19 | + BlockSweeper.expire_blocks profile.blocks.select{ |b| b.class == LocationBlock } | ||
19 | session[:notice] = _('Address was updated successfully!') | 20 | session[:notice] = _('Address was updated successfully!') |
20 | redirect_to :action => 'edit_location' | 21 | redirect_to :action => 'edit_location' |
21 | end | 22 | end |