protected function refreshQueues()
    {
        if ($this->refreshQueues) {
            $this->queues = $this->resque->queues();
        }

        if (!$this->queues) {
            if ($this->refreshQueues) {
                $this->logger->info('Refreshing queues dynamically, but there are no queues yet');
            } else {
                $this->logger->notice('Not listening to any queues, and dynamic queue refreshing is disabled');
                $this->shutdownNow();
            }
        }

        // Each call to reserve, we check the queues in a different order
        if ($this->options['shuffle_queues']) {
            shuffle($this->queues);
        } elseif ($this->options['sort_queues']) {
            sort($this->queues);
        }
    }