array_search returns false when not found. This causes the first CSS class in the $classes array to be removed ( twice ).  This was inadvertently removing some of the custom classes defined in the Menu Builder of WordPress.
Merge pull request #3896 from pronamic/fix/navMenuItems

array_search returns false when not found.