fixed errors on compiling