diff --git a/app/controllers/admin/user_fields_controller.rb b/app/controllers/admin/user_fields_controller.rb index fceecfa7d18..e6bf7b2087d 100644 --- a/app/controllers/admin/user_fields_controller.rb +++ b/app/controllers/admin/user_fields_controller.rb @@ -8,7 +8,7 @@ class Admin::UserFieldsController < Admin::AdminController field = UserField.new(params.require(:user_field).permit(*Admin::UserFieldsController.columns)) field.position = (UserField.maximum(:position) || 0) + 1 - field.required = params[:required] == "true" + field.required = params[:user_field][:required] == "true" update_options(field) json_result(field, serializer: UserFieldSerializer) do