let me refactor that a little