Skip to content

Commit

Permalink
Fix bug where tags were lost in the index when saving a document
Browse files Browse the repository at this point in the history
  • Loading branch information
vkbo committed Nov 2, 2023
1 parent b0e3cf1 commit d67cef2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion novelwriter/core/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ def _indexKeyword(self, tHandle: str, line: str, sTitle: str,
tagName = tBits[1]
self._tagsIndex.add(tagName, tHandle, sTitle, itemClass)
self._itemIndex.setHeadingTag(tHandle, sTitle, tagName)
tags[tagName] = True
tags[tagName.lower()] = True
else:
self._itemIndex.addHeadingRef(tHandle, sTitle, tBits[1:], tBits[0])

Expand Down
6 changes: 2 additions & 4 deletions sample/content/f1471bef9f2ae.nwd
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
%%~name: Space
%%~path: 15c4492bd5107/f1471bef9f2ae
%%~kind: WORLD/NOTE
%%~hash: bc139a020239c9c0d936aa9d0bcc3644ae2f370c
%%~date: Unknown/2023-08-25 16:52:06
%%~hash: b08c9796fd9918a87e107bf26606e75341a49ce8
%%~date: Unknown/2023-11-03 00:36:58
# Space

@tag: Space

Space … it’s an awful lot of nothing, with bits in it here and there. Some of which, people like to call home.


0 comments on commit d67cef2

Please sign in to comment.