Fixed some bugs, added more util usage