app/controllers/users_controller.rb
# Prevent the user's profile from being shown if the user has not set up his
# account yet.
Prevent the user's profile from being shown if the user has not set up his
account yet.
Prevent the user ' s profile from being shown if the user has not set up his account yet .
def check_user_invite_status
    return if @user.accepted_or_not_invited?
    redirect_to users_path,
                alert: 'This user has not accepted his invitation yet.'
  end
def check_user_invite_status return if @user . accepted_or_not_invited? redirect_to users_path , alert : 'This user has not accepted his invitation yet.' end
Prevent the user's profile from being shown if the user has not set up his
account yet.
Prevent the user ' s profile from being shown if the user has not set up his account yet .