Get code from nav-menu-template.php

wp-includes/nav-menu-template.php
Make navigation aware of posts that have category