I worked about three hours on this issue today, but still haven't solved the problem.

Here are lines 1429-1434 in your theme-functions.php file:


case is_single():
$cat =...