Skip to content
This repository has been archived by the owner on Jun 15, 2023. It is now read-only.

Commit

Permalink
Issue #12: ReactiveResourceReader fails with NPE when a resource is m…
Browse files Browse the repository at this point in the history
…issing
  • Loading branch information
magnet committed Aug 20, 2017
1 parent dc6709c commit 8d07490
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ private Promise<Path> getNonBundleResourcePath(ClassLoader classLoader, String r
throws URISyntaxException {
return PromiseHelper.wrap(() -> {
URL resource = classLoader.getResource(resourcePath);
if (resource == null) {
throw new FileNotFoundException(resourcePath.toString());
}
return Paths.get(resource.toURI());
});
}
Expand Down

0 comments on commit 8d07490

Please sign in to comment.