def update_user(update_user_params)
        if @user.update_attributes(update_user_params)
          render json: @user, except: [:password_digest]
        else
          render_errors 400, @user.errors.full_messages
        end
      end
def update_user(update_user_params)
        if @user.update_attributes(update_user_params)
          render json: @user, except: [:password_digest]
        else
          render_errors 400, @user.errors.full_messages
        end
      end
This method normally updates the user using permitted params.