From cc5d060bce4830d94d1d3ece06aef0600f428f1a Mon Sep 17 00:00:00 2001 From: ClemDee Date: Fri, 9 Aug 2019 16:15:07 +0200 Subject: [PATCH] Fix edit mode not default for url in drive share modal --- www/common/common-ui-elements.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 207d00336..09beddd66 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -573,9 +573,9 @@ define([ onFriendShare.reg(saveValue); var getLinkValue = function (initValue) { var val = initValue || {}; - var edit = initValue ? val.edit : Util.isChecked($(link).find('#cp-share-editable-true')); - var embed = initValue ? val.embed : Util.isChecked($(link).find('#cp-share-embed')); - var present = initValue ? val.present : Util.isChecked($(link).find('#cp-share-present')); + var edit = val.edit !== undefined ? val.edit : Util.isChecked($(link).find('#cp-share-editable-true')); + var embed = val.embed !== undefined ? val.embed : Util.isChecked($(link).find('#cp-share-embed')); + var present = val.present !== undefined ? val.present : Util.isChecked($(link).find('#cp-share-present')); var hash = (!hashes.viewHash || (edit && hashes.editHash)) ? hashes.editHash : hashes.viewHash; var href = origin + pathname + '#' + hash;