Skip to content

Commit

Permalink
revert changes on home controller
Browse files Browse the repository at this point in the history
  • Loading branch information
yksflip committed Mar 6, 2023
1 parent afd82a4 commit 54e11dc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/controllers/home_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ def reference_calculator
@bank_accounts = @types.includes(:bank_account).map(&:bank_account).uniq.compact
@bank_accounts = [BankAccount.last] if @bank_accounts.empty?
else
redirect_to root_path, alert: I18n.t('group_orders.errors.no_member')
redirect_to root_url, alert: I18n.t('group_orders.errors.no_member')
end
end

def update_profile
if @current_user.update(user_params)
@current_user.ordergroup.update(ordergroup_params) if ordergroup_params
session[:locale] = @current_user.locale
redirect_to my_profile_path, notice: I18n.t('home.changes_saved')
redirect_to my_profile_url, notice: I18n.t('home.changes_saved')
else
render :profile
end
Expand Down

0 comments on commit 54e11dc

Please sign in to comment.