def create
      user = User.new(user_params)

      if user.save
        UserMailer.confirm_account(user).deliver_now
        render json: user, status: :created
      else
        render json: user.errors, status: 422
      end
    end
def create
      user = User.new(user_params)

      if user.save
        UserMailer.confirm_account(user).deliver_now
        render json: user, status: :created
      else
        render json: user.errors, status: 422
      end
    end
Creates a new user