From: Ward Vandewege Date: Thu, 11 Feb 2021 15:25:22 +0000 (-0500) Subject: 17119: remove the default project_class again on the group model, it is X-Git-Tag: 2.2.0~110^2~11 X-Git-Url: https://git.arvados.org/arvados.git/commitdiff_plain/ba6fa2a96edde375aab6cbab0fa325c0bc08cb02 17119: remove the default project_class again on the group model, it is not needed. Arvados-DCO-1.1-Signed-off-by: Ward Vandewege --- diff --git a/services/api/app/models/arvados_model.rb b/services/api/app/models/arvados_model.rb index 2c5dee91ca..f2bae3a4b5 100644 --- a/services/api/app/models/arvados_model.rb +++ b/services/api/app/models/arvados_model.rb @@ -889,13 +889,6 @@ class ArvadosModel < ApplicationRecord }.merge(attributes['scheduling_parameters'] || {}) end - # The 'group_class' for a group should default to 'project' - def fill_group_defaults - if !attributes.key?("group_class") || attributes['group_class'].nil? || attributes['group_class'].empty? - self.group_class = 'project' - end - end - # ArvadosModel.find_by_uuid needs extra magic to allow it to return # an object in any class. def self.find_by_uuid uuid diff --git a/services/api/app/models/group.rb b/services/api/app/models/group.rb index 519dcd3072..870e0d0c45 100644 --- a/services/api/app/models/group.rb +++ b/services/api/app/models/group.rb @@ -16,7 +16,6 @@ class Group < ArvadosModel # already know how to properly treat them. attribute :properties, :jsonbHash, default: {} - before_validation :fill_group_defaults validate :ensure_filesystem_compatible_name validate :check_group_class before_create :assign_name