From 7b97c5d41ab780b228a07586b0a397e5e6e09ef7 Mon Sep 17 00:00:00 2001 From: Liang Ding Date: Fri, 3 Mar 2023 09:46:10 +0800 Subject: [PATCH] =?UTF-8?q?:art:=20=E6=8C=81=E4=B9=85=E5=8C=96=E5=B1=9E?= =?UTF-8?q?=E6=80=A7=E8=A7=86=E5=9B=BE=20https://github.com/siyuan-note/si?= =?UTF-8?q?yuan/issues/2829?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- kernel/model/attribute_view.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/kernel/model/attribute_view.go b/kernel/model/attribute_view.go index 79e43c572..df0326b2f 100644 --- a/kernel/model/attribute_view.go +++ b/kernel/model/attribute_view.go @@ -32,13 +32,13 @@ func (tx *Transaction) doInsertAttrViewBlock(operation *Operation) (ret *TxErr) tree, err := tx.loadTree(firstSrcID) if nil != err { logging.LogErrorf("load tree [%s] failed: %s", firstSrcID, err) - return &TxErr{code: TxErrCodeBlockNotFound, id: firstSrcID} + return &TxErr{code: TxErrCodeBlockNotFound, id: firstSrcID, msg: err.Error()} } avID := operation.ParentID for _, id := range operation.SrcIDs { if err = addAttributeViewBlock(id, avID, tree); nil != err { - return &TxErr{code: TxErrWriteAttributeView, id: avID} + return &TxErr{code: TxErrWriteAttributeView, id: avID, msg: err.Error()} } } return @@ -59,8 +59,6 @@ func (tx *Transaction) doRemoveAttrViewBlock(operation *Operation) (ret *TxErr) } } return - - return } func AddAttributeViewColumn(name string, typ string, columnIndex int, avID string) (err error) {