conditional checking was arse backwards
This commit is contained in:
parent
85c863deab
commit
f8ee7b2e91
|
@ -54,9 +54,9 @@ class Roda
|
||||||
shall_proxy = Random.rand(0.0..1.0) <= probability
|
shall_proxy = Random.rand(0.0..1.0) <= probability
|
||||||
|
|
||||||
if shall_proxy && ( condition.respond_to?(:call) ? condition.call : condition )
|
if shall_proxy && ( condition.respond_to?(:call) ? condition.call : condition )
|
||||||
yield(self)
|
|
||||||
else
|
|
||||||
proxy
|
proxy
|
||||||
|
else
|
||||||
|
yield(self)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
|
|
||||||
class Roda
|
class Roda
|
||||||
module Proxy
|
module Proxy
|
||||||
VERSION = '1.0.0'
|
VERSION = '1.0.1'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue