From d8dd3e222dbf1c7c1b530399b00b22ff161d0679 Mon Sep 17 00:00:00 2001
From: Erik Reid <erik.reid@geant.org>
Date: Sat, 24 May 2025 18:15:21 +0200
Subject: [PATCH] fixed if/else chain

---
 mapping_provider/backends/rmq/exchange.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mapping_provider/backends/rmq/exchange.py b/mapping_provider/backends/rmq/exchange.py
index d75aae3..ef3f5fe 100644
--- a/mapping_provider/backends/rmq/exchange.py
+++ b/mapping_provider/backends/rmq/exchange.py
@@ -196,9 +196,9 @@ class RabbitMQClient:
         self.exchange_type = exchange_type
 
         self.routing_keys: Sequence[str] = []  # for mypy
-        if routing_keys is not None:
+        if routing_keys is None:
             self.routing_keys = []
-        if isinstance(routing_keys, str):
+        elif isinstance(routing_keys, str):
             self.routing_keys = [routing_keys]
         elif isinstance(routing_keys, Sequence):
             self.routing_keys = routing_keys
-- 
GitLab