lib/prosopite.rb in prosopite-1.1.1 vs lib/prosopite.rb in prosopite-1.1.2

- old
+ new

@@ -46,17 +46,19 @@ def tc Thread.current end def pause - tc[:prosopite_scan] = false - if block_given? begin + previous = tc[:prosopite_scan] + tc[:prosopite_scan] = false yield ensure - tc[:prosopite_scan] = true + tc[:prosopite_scan] = previous end + else + tc[:prosopite_scan] = false end end def resume scan