@@ -75,7 +75,7 @@ class DBNameUniqueRaceError < Sequel::ValidationFailed; end
7575 many_to_many :security_groups ,
7676 dataset : lambda {
7777 SecurityGroup . left_join ( :security_groups_spaces , security_group_id : :id ) .
78- where ( Sequel . or ( security_groups_spaces__space_id : id , security_groups__running_default : true ) ) . distinct ( :id )
78+ where ( Sequel . or ( security_groups_spaces__space_id : id , security_groups__running_default : true ) ) . distinct ( :id )
7979 } ,
8080 eager_loader : lambda { |spaces_map |
8181 space_ids = spaces_map [ :id_map ] . keys
@@ -99,7 +99,7 @@ class DBNameUniqueRaceError < Sequel::ValidationFailed; end
9999 right_key : :staging_security_group_id ,
100100 dataset : lambda {
101101 SecurityGroup . left_join ( :staging_security_groups_spaces , staging_security_group_id : :id ) .
102- where ( Sequel . or ( staging_security_groups_spaces__staging_space_id : id , security_groups__staging_default : true ) ) . distinct ( :id )
102+ where ( Sequel . or ( staging_security_groups_spaces__staging_space_id : id , security_groups__staging_default : true ) ) . distinct ( :id )
103103 } ,
104104 eager_loader : lambda { |spaces_map |
105105 space_ids = spaces_map [ :id_map ] . keys
@@ -277,11 +277,11 @@ def number_service_keys
277277 def self . user_visibility_filter ( user )
278278 {
279279 spaces__id : user . space_developer_space_ids .
280- union ( user . space_manager_space_ids , from_self : false ) .
281- union ( user . space_auditor_space_ids , from_self : false ) .
282- union ( user . space_supporter_space_ids , from_self : false ) .
283- union ( dataset . join ( user . org_manager_org_ids , organization_id : :organization_id ) . select ( :spaces__id ) , from_self : false ) .
284- select ( :space_id )
280+ union ( user . space_manager_space_ids , from_self : false ) .
281+ union ( user . space_auditor_space_ids , from_self : false ) .
282+ union ( user . space_supporter_space_ids , from_self : false ) .
283+ union ( dataset . join ( user . org_manager_org_ids , organization_id : :organization_id ) . select ( :spaces__id ) , from_self : false ) .
284+ select ( :space_id )
285285 }
286286 end
287287
0 commit comments