forked from External/greenlight
* <fixed privacy policy workflow> * <fixed privacy policy workflow> * <changed rspec tests to handle new privacy flow> * <changed rspec tests to handle new privacy flow> * <deleted previous term validation due to changed workflow> * <fixed code style> * <reverted configuration settings> * <Updated terms and conditions for existing users (not omniauth)> * <Fix code style> * <Fixed privacy policy for omniauth> * <Fixed Travis C.I test> * <Minor code changes> * <Undo routes.rb change> * <reconfigured routes.rb>
This commit is contained in:
@ -97,13 +97,11 @@ class UsersController < ApplicationController
|
||||
redirect_to root_path
|
||||
end
|
||||
|
||||
# GET /u/terms
|
||||
# GET /terms
|
||||
def terms
|
||||
redirect_to root_path unless current_user
|
||||
|
||||
if params[:accept] == "true"
|
||||
current_user.update_attribute(accepted_terms: true)
|
||||
redirect_to current_user.main_room
|
||||
current_user.update_attributes(accepted_terms: true)
|
||||
redirect_to current_user.main_room if current_user
|
||||
end
|
||||
end
|
||||
|
||||
@ -118,6 +116,7 @@ class UsersController < ApplicationController
|
||||
end
|
||||
|
||||
def user_params
|
||||
params.require(:user).permit(:name, :email, :image, :password, :password_confirmation, :new_password, :provider)
|
||||
params.require(:user).permit(:name, :email, :image, :password, :password_confirmation,
|
||||
:new_password, :provider, :accepted_terms)
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user