Replace all %2F with a / in private link
This commit is contained in:
parent
583dce5276
commit
5cf42b88af
|
@ -181,7 +181,7 @@ OC.Share={
|
||||||
$('#privateLinkCheckbox').attr('checked', true);
|
$('#privateLinkCheckbox').attr('checked', true);
|
||||||
var link = parent.location.protocol+'//'+location.host+OC.linkTo('', 'public.php')+'?service=files&token='+token;
|
var link = parent.location.protocol+'//'+location.host+OC.linkTo('', 'public.php')+'?service=files&token='+token;
|
||||||
if (token.indexOf('&path=') == -1) {
|
if (token.indexOf('&path=') == -1) {
|
||||||
link += '&file=' + encodeURIComponent(item).replace('%2F', '/');
|
link += '&file=' + encodeURIComponent(item).replace(/%2F/g, '/');
|
||||||
} else {
|
} else {
|
||||||
// Disable checkbox if inside a shared parent folder
|
// Disable checkbox if inside a shared parent folder
|
||||||
$('#privateLinkCheckbox').attr('disabled', 'true');
|
$('#privateLinkCheckbox').attr('disabled', 'true');
|
||||||
|
|
Loading…
Reference in New Issue