Skip to content

Commit

Permalink
Merge pull request #47 from Strech/remove-extra-proc-allocation
Browse files Browse the repository at this point in the history
Remove extra Proc allocation from metrics sync.
  • Loading branch information
grobie authored Mar 3, 2017
2 parents ae01620 + cacace1 commit 105c60c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/prometheus/client/metric.rb
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ def label_set_for(labels)
@validator.validate(labels)
end

def synchronize(&block)
@mutex.synchronize(&block)
def synchronize
@mutex.synchronize { yield }
end
end
end
Expand Down

0 comments on commit 105c60c

Please sign in to comment.