locate: remove dead code