fix geography detection (fixes #11375)