From 0ae6ef59ecae7c757b6faf6fcabe0de3e02f2030 Mon Sep 17 00:00:00 2001 From: erwanlr Date: Thu, 26 Nov 2015 13:52:12 +0000 Subject: [PATCH] Fixes an issue with --cache-ttl being a Strig instead of an integer --- lib/common/browser/options.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/common/browser/options.rb b/lib/common/browser/options.rb index 28032351..8e25f5e9 100644 --- a/lib/common/browser/options.rb +++ b/lib/common/browser/options.rb @@ -3,8 +3,8 @@ class Browser module Options - attr_accessor :cache_ttl, :request_timeout, :connect_timeout - attr_reader :basic_auth, :proxy, :proxy_auth, :throttle + attr_accessor :request_timeout, :connect_timeout + attr_reader :basic_auth, :cache_ttl, :proxy, :proxy_auth, :throttle attr_writer :user_agent # Sets the Basic Authentification credentials @@ -25,6 +25,10 @@ class Browser end end + def cache_ttl=(ttl) + @cache_ttl = ttl.to_i + end + # @return [ Integer ] def max_threads @max_threads || 1