a couple extra helper functions