better organization of util functionality