fixed a type error