FIX: improves and fixes a regression with category-selector (PR #9821)

GitHub