Commit 7f027c6
committed
Support
Previously, the `TopicList`'s `RelativeTopicBase` would work incorrectly with new topics since `ITopicRepository.Load()` would load the _parent_ context's `UniqueKey`, and thus it would return content relative to the _parent_, not the new topic.
This is mitigated by temporarily creating a placeholder topic in the topic graph that can be used as the relative base. This placeholder topic must be removed from the parent's `Children` collection, as otherwise it will persist in memory, interfere with future attempts to create new children, and potentially even end up getting persisted to the database under certain circumstances (such as a recursive `Save()` triggered by an `Import()`).RelativeTopicBase with new topics1 parent 9ecf880 commit 7f027c6
1 file changed
Lines changed: 4 additions & 0 deletions
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
97 | 101 | | |
98 | 102 | | |
99 | 103 | | |
| |||
0 commit comments