dev/core#1361 Fix bug where 2 memberships created for same relationship
authoreileen <emcnaughton@wikimedia.org>
Tue, 5 Nov 2019 15:32:08 +0000 (04:32 +1300)
committereileen <emcnaughton@wikimedia.org>
Wed, 6 Nov 2019 02:38:28 +0000 (15:38 +1300)
commit6345c936fcb87bc3fac0f92dc6e7d13caddaae32
tree9193618ef4c2c5a54297df4e6db2e86c24396c40
parent3256970efd139cf3aeacf1002a8ade272c59db17
dev/core#1361 Fix bug where 2 memberships created for same relationship

Fixes a bug (likely recent regression) identified by @agileware-pengyi where duplicate inherited relationships for the same membership were being created

I've been pretty much sweating blood trying to understand the code, & have now resorted to adding a class to
generate a saner data set
CRM/Contact/BAO/Relationship.php
CRM/Member/Utils/RelationshipProcessor.php [new file with mode: 0644]
tests/phpunit/CRM/Contact/BAO/RelationshipTest.php