summaryrefslogtreecommitdiffstats
path: root/lib/roo/spreadsheet.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/roo/spreadsheet.rb')
-rw-r--r--lib/roo/spreadsheet.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/roo/spreadsheet.rb b/lib/roo/spreadsheet.rb
index 1eef58d..cdc93f0 100644
--- a/lib/roo/spreadsheet.rb
+++ b/lib/roo/spreadsheet.rb
@@ -24,7 +24,7 @@ module Roo
options[:file_warning] = :ignore
extension.tr('.', '').downcase.to_sym
else
- res = ::File.extname((path =~ /\A#{::URI.regexp}\z/) ? ::URI.parse(::URI.encode(path)).path : path)
+ res = ::File.extname((path =~ /\A#{::URI::DEFAULT_PARSER.make_regexp}\z/) ? ::URI.parse(::URI.encode(path)).path : path)
res.tr('.', '').downcase.to_sym
end
end