diff options
| -rw-r--r-- | lib/asciidoctor/pdf/ext/core/file.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/asciidoctor/pdf/ext/core/file.rb b/lib/asciidoctor/pdf/ext/core/file.rb index 9f01f258..9f46397c 100644 --- a/lib/asciidoctor/pdf/ext/core/file.rb +++ b/lib/asciidoctor/pdf/ext/core/file.rb @@ -3,6 +3,6 @@ File.singleton_class.prepend (Module.new do # NOTE: JRuby < 9.4 doesn't implement this method; JRuby 9.4 implements it incorrectly def absolute_path? path - (::Pathname.new path).absolute? && ((path.chr == '/' && File::SEPARATOR == '/') || !(URI.split path)[2]) + (::Pathname.new path).absolute? && !(%r/\A[[:alpha:]][[:alnum:]\-+]*:\/\/\S/.match? path) end end) if RUBY_ENGINE == 'jruby' |
