I am trying to hide the subcategories from the categories list widget but I cant make it work. I know i can simply remove this line:
'subnav' => qa_category_navigation_sub($parentcategories, $category['categoryid'], $selecteds, $pathprefix.$category['tags'].'/', $showqcount, $pathparams, $favoritemap),
but this will remove subcategories from everywhere they are listed in the site and not only from widget. I tried to override the function
by calling it inside the widget but this also didn't work. @Ansgar and other developers of q2a could please give me some help. I am really struggling with this. Thanks in advance.