Skip to content

Commit 2902d0d

Browse files
authored
[MJAVADOC-758] correct exception in JavadocUtil (#230)
Throw NPE, not IOException
1 parent d1c1db6 commit 2902d0d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/org/apache/maven/plugins/javadoc/JavadocUtil.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -692,10 +692,10 @@ protected static List<String> getTagletClassNames(File jarFile)
692692
*/
693693
protected static void copyResource(URL url, File file) throws IOException {
694694
if (file == null) {
695-
throw new IOException("The file can't be null.");
695+
throw new NullPointerException("The file can't be null.");
696696
}
697697
if (url == null) {
698-
throw new IOException("The url could not be null.");
698+
throw new NullPointerException("The url could not be null.");
699699
}
700700

701701
FileUtils.copyURLToFile(url, file);

0 commit comments

Comments
 (0)