Ensure we reset state for `Messagebus.track_publish`.

This commit is contained in:
Guo Xiang Tan 2017-08-21 22:29:14 +09:00
parent e8f19e004e
commit 0d46c7a19b
1 changed files with 2 additions and 1 deletions

View File

@ -13,8 +13,9 @@ module MessageBus::DiagnosticsHelper
def track_publish
@tracking = tracking = []
yield
@tracking = nil
tracking
ensure
@tracking = nil
end
end