fix useless code