position_ok? refactoring