Remove unused util funcs and clean up imports