lib/yard-contracts/formatters.rb in yard-contracts-0.1.3 vs lib/yard-contracts/formatters.rb in yard-contracts-0.1.4
- old
+ new
@@ -254,11 +254,14 @@
# so that we can call to_s on it.
def get_contract_value(type)
con = type
begin
con = Contracts.const_get(type)
- rescue StandardError # NameError
- con = eval(type) rescue StandardError
+ rescue Exception
+ begin
+ con = eval(type)
+ rescue Exception
+ end
end
con
end
end
end