From 268b474f53eddba386094272af456228aba4758a Mon Sep 17 00:00:00 2001 From: Go MAEDA Date: Thu, 1 Apr 2021 15:45:23 +0000 Subject: [PATCH] Rails 6.1: fix set roleids (#29914, #32935). MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Patch by Pavel Rosický. git-svn-id: http://svn.redmine.org/redmine/trunk@20899 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/models/member.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/models/member.rb b/app/models/member.rb index f7b4038f5..5cf7620de 100644 --- a/app/models/member.rb +++ b/app/models/member.rb @@ -76,6 +76,8 @@ class Member < ActiveRecord::Base if member_roles_to_destroy.any? member_roles_to_destroy.each(&:destroy) end + member_roles.reload + super(ids) end def <=>(member) -- 2.39.5