Skip to content

Commit

Permalink
[frontend] Use Rails logger in RabbitMQ lib
Browse files Browse the repository at this point in the history
as there is no logger variable available which caused a crash when there is no RabbitMQ configured.
  • Loading branch information
ChrisBr committed Apr 25, 2018
1 parent bfaa1b7 commit 141b359
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/api/lib/rabbitmq_bus.rb
Expand Up @@ -2,7 +2,7 @@ class RabbitmqBus
def self.send_to_bus(channel, data)
publish("#{Configuration.amqp_namespace}.#{channel}", data)
rescue Bunny::Exception, OpenSSL::SSL::SSLError => e
logger.error "Publishing to RabbitMQ failed: #{e.message}"
Rails.logger.error "Publishing to RabbitMQ failed: #{e.message}"
end

def self.publish(event_routing_key, event_payload)
Expand Down

0 comments on commit 141b359

Please sign in to comment.