lib/rabbit/publishing.rb in rabbit_messaging-0.8.1 vs lib/rabbit/publishing.rb in rabbit_messaging-0.9.0
- old
+ new
@@ -9,10 +9,10 @@
extend self
MUTEX = Mutex.new
def publish(msg)
- return if Rabbit.config.environment.in? %i[test development]
+ return if Rabbit.config.skip_publish?
pool.with_channel msg.confirm_select? do |ch|
ch.basic_publish *msg.basic_publish_args
raise MessageNotDelivered, "RabbitMQ message not delivered: #{msg}" \