🎨 Flashcards are not allowed to be modified during data sync to avoid data overwriting https://github.com/siyuan-note/siyuan/issues/10167

This commit is contained in:
Daniel 2024-01-13 21:56:42 +08:00
parent 0d21e127db
commit 43c6fabcdc
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -641,7 +641,7 @@ func (tx *Transaction) doRemoveFlashcards(operation *Operation) (ret *TxErr) {
deckLock.Lock()
defer deckLock.Unlock()
if syncingStorages.Load() {
if isSyncing.Load() {
ret = &TxErr{code: TxErrCodeDataIsSyncing}
return
}
@ -753,7 +753,7 @@ func (tx *Transaction) doAddFlashcards(operation *Operation) (ret *TxErr) {
deckLock.Lock()
defer deckLock.Unlock()
if syncingStorages.Load() {
if isSyncing.Load() {
ret = &TxErr{code: TxErrCodeDataIsSyncing}
return
}