summaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
authorVincent Petry <vincent@nextcloud.com>2021-12-09 14:58:31 +0100
committerVincent Petry <vincent@nextcloud.com>2021-12-09 14:58:31 +0100
commit4443ed2e0f3371c791fb16ba5b819e6c49a1d9dc (patch)
treeb0e704e8ef11248e30f5f4292139ec245d91ca87 /core/js
parent64cd011f47d09adf7724fb384af9039bd3525ba6 (diff)
downloadnextcloud-server-4443ed2e0f3371c791fb16ba5b819e6c49a1d9dc.tar.gz
nextcloud-server-4443ed2e0f3371c791fb16ba5b819e6c49a1d9dc.zip
Use correct icon for dir-external-root
When an external storage mount is shared with circles, it triggers the share icon state to be rerendered. The picking of the mime type icon would use the regular file icon because there is no actual icon for "dir-external-root" that is shared. This fixes the logic to use the "folder-external" icon in such scenarios. Signed-off-by: Vincent Petry <vincent@nextcloud.com>
Diffstat (limited to 'core/js')
-rw-r--r--core/js/mimetype.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/js/mimetype.js b/core/js/mimetype.js
index bad676d9357..7f206548177 100644
--- a/core/js/mimetype.js
+++ b/core/js/mimetype.js
@@ -50,7 +50,7 @@ OC.MimeType = {
return 'folder-shared';
} else if (mimeType === 'dir-public' && $.inArray('folder-public', files) !== -1) {
return 'folder-public';
- } else if (mimeType === 'dir-external' && $.inArray('folder-external', files) !== -1) {
+ } else if ((mimeType === 'dir-external' || mimeType === 'dir-external-root') && $.inArray('folder-external', files) !== -1) {
return 'folder-external';
} else if ($.inArray(icon, files) !== -1) {
return icon;