diff --git a/app/models/organization/assets.rb b/app/models/organization/assets.rb index cba3d76e6..2403f8b5c 100644 --- a/app/models/organization/assets.rb +++ b/app/models/organization/assets.rb @@ -32,6 +32,10 @@ returns if !data[ Organization.to_app_model ][ id ] local_attributes = attributes + # set temp. current attributes to assets pool to prevent + # loops, will be updated with lookup attributes later + data[ Organization.to_app_model ][ id ] = local_attributes + # get organizations key = "Organization::member_ids::#{id}" local_member_ids = Cache.get(key) diff --git a/app/models/user/assets.rb b/app/models/user/assets.rb index 7801168a4..05c8ab8d7 100644 --- a/app/models/user/assets.rb +++ b/app/models/user/assets.rb @@ -32,6 +32,10 @@ returns # do not transfer crypted pw local_attributes['password'] = '' + # set temp. current attributes to assets pool to prevent + # loops, will be updated with lookup attributes later + data[ User.to_app_model ][ id ] = local_attributes + # get linked accounts local_attributes['accounts'] = {} key = "User::authorizations::#{id}"