Fixed some compile errors due to previous merge