mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-23 05:25:50 +03:00
Merge pull request #5371 from nextcloud/bugfix/do-not-lock-if-lock-is-not-available
Edit locally. Do not lock if locking is disabled on the server.
This commit is contained in:
commit
e332929ffe
1 changed files with 2 additions and 1 deletions
|
@ -565,7 +565,8 @@ void EditLocallyJob::processLocalItem()
|
|||
const auto ok = _folderForFile->journalDb()->getFileRecord(_relativePathToRemoteRoot, &rec);
|
||||
Q_ASSERT(ok);
|
||||
|
||||
if (rec.isDirectory()) { // Directories not lock-able
|
||||
// Do not lock if it is a directory or lock is not available on the server
|
||||
if (rec.isDirectory() || !_accountState->account()->capabilities().filesLockAvailable()) {
|
||||
openFile();
|
||||
} else {
|
||||
lockFile();
|
||||
|
|
Loading…
Reference in a new issue