lib/fluffle/server.rb in fluffle-1.0.1 vs lib/fluffle/server.rb in fluffle-1.1.0

- old
+ new

@@ -161,9 +161,17 @@ stack.call do @exchange.publish Oj.dump(response), routing_key: reply_to, correlation_id: response['id'] end + + if handler.respond_to? :after_response + begin + handler.after_response request: request + rescue => err + log_error(err) if Fluffle.logger.error? + end + end end # handler - Instance of a `Handler` that may receive `#call` # request - `Hash` representing a decoded Request def call_handler(handler:, request:)