added utils, cleaned up code