lib/bbk/amqp/message.rb in bbk-amqp-1.0.0.109994 vs lib/bbk/amqp/message.rb in bbk-amqp-1.0.0.152789
- old
+ new
@@ -15,10 +15,10 @@
@delivery_info = delivery_info.to_h.merge(
message_consumer: consumer,
protocols: consumer.protocols,
queue: amqp_consumer&.queue_name
)
- @headers = @properties.except(:headers).merge(properties[:headers]).with_indifferent_access
+ @headers = @properties.except(:headers).merge(properties[:headers].presence || {}).with_indifferent_access
@payload = begin
Oj.load(body).with_indifferent_access
rescue StandardError
{}.with_indifferent_access
end