Skip to content

Commit

Permalink
Fix live server hang during folgezettel cycles (#214)
Browse files Browse the repository at this point in the history
* fix folgezettel cycle detection

insert into visited set before recursion
fixes #210

* bump version
  • Loading branch information
edrex authored Dec 9, 2021
1 parent 526e81c commit 243f8dc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion emanote.cabal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cabal-version: 2.4
name: emanote
version: 0.4.0.0
version: 0.4.1.0
license: AGPL-3.0-only
copyright: 2021 Sridhar Ratnakumar
maintainer: srid@srid.ca
Expand Down
2 changes: 1 addition & 1 deletion src/Emanote/Model/Graph.hs
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ modelFolgezettelAncestorTree r0 model =
gets (parentModelR `Set.member`) >>= \case
True -> pure Nothing
False -> do
sub <- go parentModelR
modify $ Set.insert parentModelR
sub <- go parentModelR
pure $ Just $ Node parentR sub
isFolgezettel = \case
Rel.URTWikiLink (WL.WikiLinkBranch, _wl) ->
Expand Down

0 comments on commit 243f8dc

Please sign in to comment.