Skip to content

Commit

Permalink
fix(topics): keep track of categories for all topics in toc, not just…
Browse files Browse the repository at this point in the history
… leaves
  • Loading branch information
nsantacruz committed Dec 14, 2024
1 parent 8029a14 commit 23bd030
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion static/js/sefaria/sefaria.js
Original file line number Diff line number Diff line change
Expand Up @@ -2785,8 +2785,8 @@ _media: {},
this._topicTocCategory = this.topic_toc.reduce(this._initTopicTocCategoryReducer, {});
},
_initTopicTocCategoryReducer: function(a,c) {
a[c.slug] = c.parents;
if (!c.children) {
a[c.slug] = c.parents;
return a;
}
if (!c.parents) {
Expand Down

0 comments on commit 23bd030

Please sign in to comment.