]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
restructure filters on services
authorEvan Prodromou <evan@prodromou.name>
Tue, 3 Jun 2008 11:17:50 +0000 (07:17 -0400)
committerEvan Prodromou <evan@prodromou.name>
Tue, 3 Jun 2008 11:17:50 +0000 (07:17 -0400)
darcs-hash:20080603111750-84dde-5b3eb37cc05ceaec991951338d55d38a2e0a5f2d.gz

lib/omb.php

index 481aa6c02479437c6bb0a32a7835851edcc2320a..c402e087644e27ee8269cd0c2da39355b3cfa025 100644 (file)
@@ -72,11 +72,13 @@ function omb_service_filter($type) {
 }
        
 function omb_match_service($service, $type) {
-       if ($service && $service->matchTypes(array($type))) {
-               return TRUE;
-       } else {
-               return FALSE;
+       if ($service) {
+               $types = $service->matchTypes(array($type));
+               if (in_array($type, $types)) {
+                       return TRUE;
+               }
        }
+       return FALSE;
 }
 
 function omb_service_uri($service) {