Skip to content

Commit 8c0fd3c

Browse files
author
Vincent Potucek
committed
Test unused stream in DefaultPluginXmlFactory#write
1 parent 90bf618 commit 8c0fd3c

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

impl/maven-impl/src/main/java/org/apache/maven/impl/DefaultModelXmlFactory.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ public void write(XmlWriterRequest<Model> request) throws XmlWriterException {
121121
Writer writer = request.getWriter();
122122
Function<Object, String> inputLocationFormatter = request.getInputLocationFormatter();
123123
if (writer == null && outputStream == null && path == null) {
124-
throw new IllegalArgumentException("writer, output stream, or path must be non null");
124+
throw new IllegalArgumentException("writer, outputStream or path must be non null");
125125
}
126126
try {
127127
MavenStaxWriter w = new MavenStaxWriter();

impl/maven-impl/src/main/java/org/apache/maven/impl/DefaultPluginXmlFactory.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ public void write(XmlWriterRequest<PluginDescriptor> request) throws XmlWriterEx
9696
OutputStream outputStream = request.getOutputStream();
9797
Writer writer = request.getWriter();
9898
if (writer == null && outputStream == null && path == null) {
99-
throw new IllegalArgumentException("writer, output stream, or path must be non null");
99+
throw new IllegalArgumentException("writer, outputStream or path must be non null");
100100
}
101101
write(writer, request.getContent(), outputStream, path);
102102
}

0 commit comments

Comments
 (0)