Better handling of NilClassException when no queues are defined