Bugfix in neighborhood finding