Add missing use statement and remove dead code