moved util code to object