summaryrefslogtreecommitdiff
path: root/kombu/transport/redis.py
diff options
context:
space:
mode:
Diffstat (limited to 'kombu/transport/redis.py')
-rw-r--r--kombu/transport/redis.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/kombu/transport/redis.py b/kombu/transport/redis.py
index 3ee049cb..164c8c2c 100644
--- a/kombu/transport/redis.py
+++ b/kombu/transport/redis.py
@@ -662,11 +662,8 @@ class Channel(virtual.Channel):
def _put(self, queue, message, **kwargs):
"""Deliver message."""
- try:
- pri = max(min(int(
- message['properties']['delivery_info']['priority']), 9), 0)
- except (TypeError, ValueError, KeyError):
- pri = 0
+ pri = self._get_message_priority(message)
+
with self.conn_or_acquire() as client:
client.lpush(self._q_for_pri(queue, pri), dumps(message))