clear some useless codes