Solved refresh bug in connect.erb