Code Duplication    Length = 6-6 lines in 2 locations

src/Dispatcher/ObjectMapDispatcher.php 2 locations

@@ 90-95 (lines=6) @@
87
88
    public function disconnectAll($name, $object)
89
    {
90
        if (is_object($object)) {
91
            $listners = $this->doGetListeners();
92
            if ($listners && $this->hadListeners($name, $object)) {
93
                $listners[$object][$name] = [];
94
            }
95
        }
96
    }
97
98
    /**
@@ 109-114 (lines=6) @@
106
    public function hasListeners($name, $object)
107
    {
108
        $listners = $this->doGetListeners();
109
        if (!$this->hadListeners($name, $object)) {
110
            $res = false;
111
        } else {
112
            $listners = $this->doGetListeners();
113
            $res = (bool) count($listners[$object][$name]);
114
        }
115
116
        return $res;
117
    }