fixes #79: When you remove a post from a pool, the post still shows the pool in its left sidebar
This commit is contained in:
@@ -35,8 +35,11 @@ class PoolsController < ApplicationController
|
|||||||
end
|
end
|
||||||
|
|
||||||
def update
|
def update
|
||||||
|
# need to do this in order for synchronize! to work correctly
|
||||||
@pool = Pool.find(params[:id])
|
@pool = Pool.find(params[:id])
|
||||||
@pool.update_attributes(params[:pool])
|
@pool.attributes = params[:pool]
|
||||||
|
@pool.synchronize!
|
||||||
|
@pool.save
|
||||||
respond_with(@pool, :notice => "Pool updated")
|
respond_with(@pool, :notice => "Pool updated")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user