Bug fix when categories are assigned to products.