summaryrefslogtreecommitdiffstats
path: root/core/js/share.js
diff options
context:
space:
mode:
authorMichael Gapczynski <mtgap@owncloud.com>2012-08-24 10:43:42 -0400
committerMichael Gapczynski <mtgap@owncloud.com>2012-08-24 15:12:16 -0400
commitfedb3641f9cdd0358951e6b794f5d3cb6d6465cb (patch)
tree2540028ce0730e3af4a5512092ba332b90ad0622 /core/js/share.js
parentee04b626b4c6c3a74bd0011be921660b5b8e6a66 (diff)
downloadnextcloud-server-fedb3641f9cdd0358951e6b794f5d3cb6d6465cb.tar.gz
nextcloud-server-fedb3641f9cdd0358951e6b794f5d3cb6d6465cb.zip
Determine if reshare needs to be checked
Diffstat (limited to 'core/js/share.js')
-rw-r--r--core/js/share.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/core/js/share.js b/core/js/share.js
index 810a4e7c0a5..b246849b479 100644
--- a/core/js/share.js
+++ b/core/js/share.js
@@ -32,6 +32,7 @@ OC.Share={
},
loadItem:function(itemType, itemSource) {
var data = '';
+ var checkReshare = true;
// Switch file sources to path to check if status is set
if (itemType == 'file' || itemType == 'folder') {
var filename = $('tr').filterAttr('data-id', String(itemSource)).data('file');
@@ -40,6 +41,9 @@ OC.Share={
} else {
var item = $('#dir').val() + '/' + filename;
}
+ if (item.substring(0, 8) != '/Shared/') {
+ checkReshare = false;
+ }
} else {
var item = itemSource;
}
@@ -48,7 +52,7 @@ OC.Share={
} else {
checkShares = true;
}
- $.ajax({type: 'GET', url: OC.filePath('core', 'ajax', 'share.php'), data: { fetch: 'getItem', itemType: itemType, itemSource: itemSource, checkShares: checkShares }, async: false, success: function(result) {
+ $.ajax({type: 'GET', url: OC.filePath('core', 'ajax', 'share.php'), data: { fetch: 'getItem', itemType: itemType, itemSource: itemSource, checkReshare: checkReshare, checkShares: checkShares }, async: false, success: function(result) {
if (result && result.status === 'success') {
data = result.data;
} else {