store_navcats var scoping fix