mirror of
https://github.com/corda/corda.git
synced 2025-03-22 12:05:59 +00:00
Minor: don't check the file name in an upload if there isn't one
This commit is contained in:
parent
29e58ce3db
commit
6ac05c2edb
@ -45,7 +45,7 @@ class DataUploadServlet : HttpServlet() {
|
||||
val messages = ArrayList<String>()
|
||||
while (iterator.hasNext()) {
|
||||
val item = iterator.next()
|
||||
if (!acceptor.acceptableFileExtensions.any { item.name.endsWith(it) }) {
|
||||
if (item.name != null && !acceptor.acceptableFileExtensions.any { item.name.endsWith(it) }) {
|
||||
resp.sendError(HttpServletResponse.SC_BAD_REQUEST,
|
||||
"${item.name}: Must be have a filename ending in one of: ${acceptor.acceptableFileExtensions}")
|
||||
return
|
||||
|
Loading…
x
Reference in New Issue
Block a user