cleanup useless variables and imports