removed comments and dead code in character