Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: 支持间隔复习 https://github.com/siyuan-note/siyuan/issues/6710

Liang Ding02d3a3a12bc7
diff --git a/kernel/model/flashcard.go b/kernel/model/flashcard.go
index 295cc0f5ec..46774ec324 100644
--- a/kernel/model/flashcard.go
+++ b/kernel/model/flashcard.go
@@ -88,8 +88,8 @@ func GetDueFlashcards(deckID string) (ret []*Flashcard, err error) {
cards := deck.Dues()
for _, card := range cards {
blockID := card.BlockID()
- _, getErr := GetBlock(blockID)
- if nil != getErr {
+
+ if nil == treenode.GetBlockTree(blockID) {
continue
}
ret = append(ret, &Flashcard{
@@ -109,8 +109,7 @@ func getAllDueFlashcards() (ret []*Flashcard, err error) {
cards := deck.Dues()
for _, card := range cards {
blockID := card.BlockID()
- _, getErr := GetBlock(blockID)
- if nil != getErr {
+ if nil == treenode.GetBlockTree(blockID) {
continue
}