Skip to content

Commit

Permalink
Default to permanent link passwords
Browse files Browse the repository at this point in the history
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
  • Loading branch information
PVince81 committed Apr 13, 2022
1 parent f5c8fa4 commit 2c2b238
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion apps/sharebymail/lib/ShareByMailProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ public function create(IShare $share) {

// Sends share password to receiver when it's a permanent one (otherwise she will have to request it via the showShare UI)
// or to owner when the password shall be given during a Talk session
if ($this->config->getSystemValue('allow_mail_share_permanent_password') || $share->getSendPasswordByTalk()) {
if ($this->config->getSystemValue('allow_mail_share_permanent_password', true) || $share->getSendPasswordByTalk()) {
$send = $this->sendPassword($share, $password);
if ($passwordEnforced && $send === false) {
$this->sendPasswordToOwner($share, $password);
Expand Down
2 changes: 1 addition & 1 deletion lib/private/Share20/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -1175,7 +1175,7 @@ private function updateSharePasswordIfNeeded(IShare $share, IShare $originalShar
* Set the share's password expiration time
*/
private function setSharePasswordExpirationTime(IShare $share): void {
if ($this->config->getSystemValue('allow_mail_share_permanent_password')) {
if ($this->config->getSystemValue('allow_mail_share_permanent_password', true)) {
// Sets password expiration date to NULL
$share->setPasswordExpirationTime();
return;
Expand Down

0 comments on commit 2c2b238

Please sign in to comment.