minor refactor, cleanup