API endpoints should return a response, not nil

This commit is contained in:
Robin Ward
2019-12-30 10:14:29 -05:00
parent bc4c40abd4
commit 5214f82841
2 changed files with 14 additions and 1 deletions

View File

@ -301,7 +301,7 @@ class Admin::UsersController < Admin::AdminController
@user.deactivate(current_user)
StaffActionLogger.new(current_user).log_user_deactivate(@user, I18n.t('user.deactivated_by_staff'), params.slice(:context))
refresh_browser @user
render body: nil
render json: success_json
end
def silence