discourse:main
← jjaffeux:name-description
opened 09:37PM - 13 Aug 24 UTC
`defaultCategoryLinkRenderer` is using a fake category object which doesn’t have… access to the functions and getters of category model.
This had been incorrectly set in https://github.com/discourse/discourse/commit/c197daa04c3114184cbd3ec2f1cfade1b5701793
As we don't get a real category object, we have to call the transformers manually and also pass the fake category object as context, this is not ideal as people might try to access properties in the transformer which are not available on the category object given they will be different based on the context. Hopefully one day this helper and all the chain can be refactored to use a real category model.
This commit also adds tests for these two properties in the category-link helper.