Skip to content

Commit

Permalink
Fix to use root_path instead of home_path
Browse files Browse the repository at this point in the history
  • Loading branch information
carolinesalib committed Feb 14, 2020
1 parent 37750a5 commit 285199d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/controllers/ngo_area/users_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def update
@user.update(params_user)

if current_user == @user && !@user.admin?
redirect_to home_index_path
redirect_to root_path
else
redirect_to ngo_area_users_path
end
Expand Down
2 changes: 1 addition & 1 deletion spec/controllers/ngo_area/users_controller_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
end

it 'redirects to Home' do
expect(response).to redirect_to(home_index_path)
expect(response).to redirect_to(root_path)
end
end
end
Expand Down

0 comments on commit 285199d

Please sign in to comment.