diff --git a/lib/vitals_image/analyzer/url_analyzer.rb b/lib/vitals_image/analyzer/url_analyzer.rb index 0a0d000..0eb421d 100644 --- a/lib/vitals_image/analyzer/url_analyzer.rb +++ b/lib/vitals_image/analyzer/url_analyzer.rb @@ -34,7 +34,7 @@ def open(file) def download uri = URI.parse(source.key) io = uri.open(ssl_verify_mode: ssl_verify_mode) - uri_path = reduce_uri_path(uri.path) + uri_path = truncate_uri_path(uri.path) downloaded = Tempfile.new([File.basename(uri_path), File.extname(uri_path)], binmode: true) if io.is_a?(Tempfile) @@ -47,7 +47,7 @@ def download downloaded end - def reduce_uri_path(uri_path) + def truncate_uri_path(uri_path) filename, extension = uri_path.split(".") filename = filename[0..200]