fixed errors in compile