DaanHoogland commented on code in PR #7915:
URL: https://github.com/apache/cloudstack/pull/7915#discussion_r1307314820


##########
plugins/user-authenticators/ldap/src/main/java/org/apache/cloudstack/ldap/LdapManagerImpl.java:
##########
@@ -125,10 +134,28 @@ public void onPublishMessage(String senderAddress, String 
subject, Object args)
                 }
             }
         });
-
-        return true;
     }
 
+    private void addDomainRemovalListener() {
+        messageBus.subscribe(DomainManager.MESSAGE_REMOVE_DOMAIN_EVENT, new 
MessageSubscriber() {
+            @Override
+            public void onPublishMessage(String senderAddress, String subject, 
Object args) {
+                try {
+                    final Domain domain = 
domainDao.findByIdIncludingRemoved((Long) args);
+                    long domainId = domain.getId();
+                    LdapTrustMapVO ldapTrustMapVO = 
_ldapTrustMapDao.findByDomainId(domainId);

Review Comment:
   there is no consistency in these names, sorry. This one returns a single 
`LdapTrustMapVO`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to