Only a few categories showing up in site.json when max_category_nesting = 3

Since I switched to max_category_nesting = 3, I noticed that my WP-Discourse is no longer pulling in the full list of categories. If I visit /site.json, I can only see 5 categories. If I visit /categories.json, I think I see all the 1st- and 2nd-level categories, with the 3rd-level category IDs listed under the 2nd-level categories. However, WP-Discourse populates its list of categories using /site.json.

Also, when I type /site.json into a window in which I’m logged in as admin, it only shows 5 categories. If I do it in an incognito window, it shows 26. In admin logged in window with /categories.json, it shows 33.

Any idea on what might be happening?

I manually updated the plugin-utilities.php file to read from categories.json and not site.json, and then updated to make sure it read the right json object (in site.json, categories is 1st level, and is 2nd level in categories.json).

However, I have 49 categories and only 33 are showing up in the categories.json as well.

So for the time being, I just manually added the one category that I wanted that was missing.

Still not sure if this is a max_category_nesting=3 problem, but even if it’s not, I think going forward wp-discourse polling the categories from categories.json may be smoother.