public function supportsControllerAndAction($controller, $action)
    {
        if (null === $this->blacklist) {
            if (null === $this->whitelist) {
                // plugin has global scope
                return true;
            }
            // we use a whitelist so ensure the controller is in the whitelist
            if (!isset($this->whitelist[$controller])) {
                return false;
            }
            // the whitelisted controller could be an array of actions or it could
            // be mapped to the "all" string
            if (is_array($this->whitelist[$controller])) {
                return in_array($action, $this->whitelist[$controller]);
            }
            return (self::ALL_ACTIONS === (string)$this->whitelist[$controller]);
        }
        // if the controller isn't in the blacklist at all, we're good
        if (!isset($this->blacklist[$controller])) {
            return true;
        }

        // if the controller is not an array we return false
        // otherwise we check if the action is listed in the array
        return is_array($this->blacklist[$controller]) &&
              !in_array($action, $this->blacklist[$controller]);
    }