diff --git a/pyproject.toml b/pyproject.toml index 6ca5159..8d17ba5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -6,7 +6,7 @@ build-backend = "setuptools.build_meta" [project] name = "amqpstorm-flask" -version = "0.4.0" +version = "0.4.1" description = "amqpstorm library for Flask" readme = "README.md" authors = [{ name = "Inuits", email = "developers@inuits.eu" }] diff --git a/src/amqpstorm_flask/RabbitMQ.py b/src/amqpstorm_flask/RabbitMQ.py index 95625c6..9e5c6b1 100644 --- a/src/amqpstorm_flask/RabbitMQ.py +++ b/src/amqpstorm_flask/RabbitMQ.py @@ -198,10 +198,7 @@ def decorator(f): queue = f.__name__.replace("_", getenv("MQ_DELIMITER", ".")) if queue_name is None else queue_name enabled_queues = None if getenv("MQ_QUEUES") is None else getenv("MQ_QUEUES").split(",") - if enabled_queues is None: - all_queues_enabled = True - else: - all_queues_enabled = False + all_queues_enabled = enabled_queues is None if queue in enabled_queues or all_queues_enabled: @wraps(f)