Fix OpenJDK scraper

pull/1024/head
Jasper van Merle 6 years ago committed by GitHub
parent b5bd218e27
commit 8325ed78ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -29,7 +29,7 @@ module Docs
def request_one(url)
assert_source_directory_exists
Response.new read_file(url_to_path(url)), URL.parse(url)
Response.new read_file(File.join(source_directory, url_to_path(url))), URL.parse(url)
end
def request_all(urls)
@ -50,7 +50,7 @@ module Docs
end
def read_file(path)
File.read(File.join(source_directory, path))
File.read(path)
rescue
instrument 'warn.doc', msg: "Failed to open file: #{path}"
nil

Loading…
Cancel
Save