delete unuseful codes