Improve RemoteFileTemplate invalid payload except.

- include the invalid payload type
This commit is contained in:
Gary Russell
2019-07-23 14:11:07 -04:00
parent 0259d0820c
commit ce85b64aa8

View File

@@ -514,7 +514,9 @@ public class RemoteFileTemplate<F> implements RemoteFileOperations<F>, Initializ
name = "InputStream payload";
}
else {
throw new IllegalArgumentException("Unsupported payload type. The only supported payloads are " +
throw new IllegalArgumentException("Unsupported payload type ["
+ payload.getClass().getName()
+ "]. The only supported payloads are " +
"java.io.File, java.lang.String, byte[], and InputStream");
}
if (dataInputStream == null) {