summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/js/share.js7
1 files changed, 6 insertions, 1 deletions
diff --git a/core/js/share.js b/core/js/share.js
index 4c8fd874107..71e6136bf71 100644
--- a/core/js/share.js
+++ b/core/js/share.js
@@ -122,7 +122,12 @@ OC.Share={
callback(result.data);
}
} else {
- OC.dialogs.alert(result.data.message, t('core', 'Error while sharing'));
+ if (result.data && result.data.message) {
+ var msg = result.data.message;
+ } else {
+ var msg = t('core', 'Error');
+ }
+ OC.dialogs.alert(msg, t('core', 'Error while sharing'));
}
});
},