Fixed cast to CostUnit.