You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openmeetings.apache.org by so...@apache.org on 2019/07/18 13:46:20 UTC

[openmeetings] branch 4.0.x updated: [OPENMEETINGS-2088] upload without file selection produces no error

This is an automated email from the ASF dual-hosted git repository.

solomax pushed a commit to branch 4.0.x
in repository https://gitbox.apache.org/repos/asf/openmeetings.git


The following commit(s) were added to refs/heads/4.0.x by this push:
     new 83167eb  [OPENMEETINGS-2088] upload without file selection produces no error
83167eb is described below

commit 83167eb8c3573b97658b772c1bcf89c486ba246c
Author: Maxim Solodovnik <so...@gmail.com>
AuthorDate: Thu Jul 18 20:45:38 2019 +0700

    [OPENMEETINGS-2088] upload without file selection produces no error
---
 .../apache/openmeetings/web/room/sidebar/UploadDialog.java  | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/UploadDialog.java b/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/UploadDialog.java
index 44c7563..8f59882 100644
--- a/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/UploadDialog.java
+++ b/openmeetings-web/src/main/java/org/apache/openmeetings/web/room/sidebar/UploadDialog.java
@@ -75,7 +75,18 @@ public class UploadDialog extends AbstractFormDialog<String> {
 	private static final long serialVersionUID = 1L;
 	private static final Logger log = Red5LoggerFactory.getLogger(UploadDialog.class, getWebAppRootKey());
 	private final KendoFeedbackPanel feedback = new KendoFeedbackPanel("feedback", new Options("button", true));
-	private final Form<String> form = new Form<>("form");
+	private final Form<String> form = new Form<>("form") {
+		private static final long serialVersionUID = 1L;
+
+		protected boolean handleMultiPart() {
+			try {
+				return super.handleMultiPart();
+			} catch (Exception e) {
+				log.warn("Multipart processing failed {}", e.getMessage());
+			}
+			return true;
+		}
+	};
 	private DialogButton upload;
 	private DialogButton cancel;
 	private final FileUploadField uploadField = new FileUploadField("file", new IModel<List<FileUpload>>() {