Closed amitaibu closed 8 years ago
Update: I have created the manager, and kept only the most used proxy methods in \Drupal\og\Og
. Next is working on the tests.
Most tests fixed - we are now down to the last two unit tests methods
I believe tests should return green now..
Cool, tests are green. I'll just rename class to MembershipManager
and it should be good to go.
Ready for review.
PR mostly moves methods to a new service, and keeps only a few methods in \Drupal\og\Og
.
Also since we have this new service, the ::setup
for unit tests for ::userAccess
have been cleaned up a bit
I prefer to get things in, so it will unblock other PRs. We can always revisit later.
/cc @pfrenssen @RoySegall
Looks good to me except for this
/** @var \Drupal\og\MembershipManagerInterface $membership_manager */
$membership_manager = \Drupal::service('og.membership_manager');
This part appear multiple times and I think, IMO, we can convert it to:
$membership_manager = Og::membershipManager();
296