From b4107c3442da31bfa3add4daede9a6bbcc8eb028 Mon Sep 17 00:00:00 2001
From: Robin Appelman <robin@icewind.nl>
Date: Mon, 2 Nov 2020 16:07:50 +0100
Subject: [PATCH] ensure filepicker list is empty before populating

Signed-off-by: Robin Appelman <robin@icewind.nl>
---
 core/src/OC/dialogs.js | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/core/src/OC/dialogs.js b/core/src/OC/dialogs.js
index e7e5ca4d310..df0794711f1 100644
--- a/core/src/OC/dialogs.js
+++ b/core/src/OC/dialogs.js
@@ -1164,6 +1164,8 @@ const Dialogs = {
 				self.$fileListHeader.show()
 			}
 
+			self.$filelist.empty();
+
 			$.each(files, function(idx, entry) {
 				entry.icon = OC.MimeType.getIconUrl(entry.mimetype)
 				var simpleSize, sizeColor
-- 
GitLab