projects
/
nextcloud-desktop.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aa74448
)
Edit locally. Do not lock if locking is disabled on the server.
author
alex-z
<blackslayer4@gmail.com>
Thu, 26 Jan 2023 16:00:14 +0000
(17:00 +0100)
committer
alex-z
<blackslayer4@gmail.com>
Thu, 26 Jan 2023 16:00:14 +0000
(17:00 +0100)
Signed-off-by: alex-z <blackslayer4@gmail.com>
src/gui/editlocallyjob.cpp
patch
|
blob
|
history
diff --git
a/src/gui/editlocallyjob.cpp
b/src/gui/editlocallyjob.cpp
index 7764e0b053f3596a7325a4340a37b2b6d36b70d1..a95ad1375dca539edc615753edd47a526b66369a 100644
(file)
--- a/
src/gui/editlocallyjob.cpp
+++ b/
src/gui/editlocallyjob.cpp
@@
-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();