public function detach($event, $callback)
    {
        if (!isset($this->eventListeners[$event]) || $this->eventListeners[$event]->isEmpty()) {
            return false;
        }

        $removed = false;
        $listeners = $this->eventListeners[$event];
        $newListeners = new ListenerQueue();

        $listeners->setExtractFlags(ListenerQueue::EXTR_BOTH);
        foreach ($listeners as $item) {
            if ($item['data'] === $callback) {
                $removed = true;
                continue;
            }

            $newListeners->insert($item['data'], $item['priority']);
        }
        $listeners->setExtractFlags(ListenerQueue::EXTR_DATA);

        $this->eventListeners[$event] = $newListeners;

        return $removed;
    }