aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/src
diff options
context:
space:
mode:
authorVarun Patil <varunpatil@ucla.edu>2025-02-26 11:50:39 -0800
committernextcloud-command <nextcloud-command@users.noreply.github.com>2025-02-27 11:10:40 +0000
commitdbef6977db5b89ae8008754974d2b048f15b3cf3 (patch)
tree1a763905a6f0df891c81cb5c0f5d4dd04c0c5201 /apps/files/src
parent774afcb37542d831065a14cce3bc8408b5924515 (diff)
downloadnextcloud-server-dbef6977db5b89ae8008754974d2b048f15b3cf3.tar.gz
nextcloud-server-dbef6977db5b89ae8008754974d2b048f15b3cf3.zip
fix(files): exception when share-attributes is undefined
Signed-off-by: Varun Patil <varunpatil@ucla.edu> Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
Diffstat (limited to 'apps/files/src')
-rw-r--r--apps/files/src/services/FileInfo.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files/src/services/FileInfo.ts b/apps/files/src/services/FileInfo.ts
index d4c587794f9..18629845cca 100644
--- a/apps/files/src/services/FileInfo.ts
+++ b/apps/files/src/services/FileInfo.ts
@@ -22,7 +22,7 @@ export default function(node: Node) {
permissions: node.permissions,
mountType: node.attributes['mount-type'],
sharePermissions: node.attributes['share-permissions'],
- shareAttributes: JSON.parse(node.attributes['share-attributes']),
+ shareAttributes: JSON.parse(node.attributes['share-attributes'] || '[]'),
type: node.type === 'file' ? 'file' : 'dir',
})