Topic list sorting not applied on refresh for tags pages

Attempting to load a tags topic list sorted does not work in Chrome/Firefox with JS enabled. You must click the replies table header for sort to work, loading the page directly (for example https://meta.discourse.org/tags/faq-material?order=posts does not work, and sort breaks if you refresh the page.

Sorting is maintained on direct load and search for other topic lists, like /latest or /c/{category-slug}/latest.

3 Likes

This would fix it:

However, I think this is kind of a minor bug and would prefer to merge this post 2.2 release.

4 Likes

I am unclear, is this fix risky??

Shouldn’t be very risky, I just had to change some of the logic and also used the opportunity to refactor this file which was using old ember/js patterns. I will test it more today and merge it.

3 Likes

I greatly simplified the PR, merged in:

3 Likes