summaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
authorJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2018-11-05 10:46:13 +0100
committerJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2018-11-05 10:50:06 +0100
commit11b6c225959601330321733646e5957a374a8aec (patch)
tree7330d00aadfc3bf8dbadd410d9c02696f4513da9 /core/js
parent934d08b2e8b0f6f8616882b9c08d1bec4db22eb2 (diff)
downloadnextcloud-server-11b6c225959601330321733646e5957a374a8aec.tar.gz
nextcloud-server-11b6c225959601330321733646e5957a374a8aec.zip
Fix password enforce on public share links
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Diffstat (limited to 'core/js')
-rw-r--r--core/js/share/sharedialoglinkshareview.handlebars2
-rw-r--r--core/js/sharedialoglinkshareview.js6
-rw-r--r--core/js/sharetemplates.js4
3 files changed, 9 insertions, 3 deletions
diff --git a/core/js/share/sharedialoglinkshareview.handlebars b/core/js/share/sharedialoglinkshareview.handlebars
index 64f52704290..4f58f632d1b 100644
--- a/core/js/share/sharedialoglinkshareview.handlebars
+++ b/core/js/share/sharedialoglinkshareview.handlebars
@@ -1,7 +1,7 @@
{{#if shareAllowed}}
<ul class="shareWithList">
{{#if nolinkShares}}
- <li data-share-id="new-share">
+ <li data-share-id="{{newShareId}}">
<div class="avatar icon-public-white"></div>
<span class="username">{{newShareLabel}}</span>
<span class="sharingOptionsGroup">
diff --git a/core/js/sharedialoglinkshareview.js b/core/js/sharedialoglinkshareview.js
index e5af4ad1f17..5dc7d706720 100644
--- a/core/js/sharedialoglinkshareview.js
+++ b/core/js/sharedialoglinkshareview.js
@@ -45,6 +45,9 @@
/** @type {string} **/
password: '',
+ /** @type {string} **/
+ newShareId: 'new-share',
+
events: {
// open menu
'click .share-menu .icon-more': 'onToggleMenu',
@@ -650,7 +653,8 @@
newShareLabel: t('core', 'Share link'),
newShareTitle: t('core', 'New share link'),
pendingPopoverMenu: pendingPopoverMenu,
- showPending: this.showPending === 'new',
+ showPending: this.showPending === this.newShareId,
+ newShareId: this.newShareId,
}));
this.delegateEvents();
diff --git a/core/js/sharetemplates.js b/core/js/sharetemplates.js
index 0f1762c5f05..619215d8083 100644
--- a/core/js/sharetemplates.js
+++ b/core/js/sharetemplates.js
@@ -10,7 +10,9 @@ templates['sharedialoglinkshareview'] = template({"1":function(container,depth0,
},"2":function(container,depth0,helpers,partials,data) {
var stack1, helper, alias1=depth0 != null ? depth0 : (container.nullContext || {}), alias2=helpers.helperMissing, alias3="function", alias4=container.escapeExpression;
- return " <li data-share-id=\"new-share\">\n <div class=\"avatar icon-public-white\"></div>\n <span class=\"username\">"
+ return " <li data-share-id=\""
+ + alias4(((helper = (helper = helpers.newShareId || (depth0 != null ? depth0.newShareId : depth0)) != null ? helper : alias2),(typeof helper === alias3 ? helper.call(alias1,{"name":"newShareId","hash":{},"data":data}) : helper)))
+ + "\">\n <div class=\"avatar icon-public-white\"></div>\n <span class=\"username\">"
+ alias4(((helper = (helper = helpers.newShareLabel || (depth0 != null ? depth0.newShareLabel : depth0)) != null ? helper : alias2),(typeof helper === alias3 ? helper.call(alias1,{"name":"newShareLabel","hash":{},"data":data}) : helper)))
+ "</span>\n <span class=\"sharingOptionsGroup\">\n <div class=\"share-menu\">\n <a href=\"#\" class=\"icon icon-add new-share has-tooltip "
+ ((stack1 = helpers["if"].call(alias1,(depth0 != null ? depth0.showPending : depth0),{"name":"if","hash":{},"fn":container.program(3, data, 0),"inverse":container.noop,"data":data})) != null ? stack1 : "")