diff --git a/source/Ox.Geo/Ox.Geo.js b/source/Ox.Geo/Ox.Geo.js index ac9c3520..081edd4a 100644 --- a/source/Ox.Geo/Ox.Geo.js +++ b/source/Ox.Geo/Ox.Geo.js @@ -150,7 +150,7 @@ Ox.load.Geo = function(options, callback) { Ox.getCountryByGeoname = function(geoname) { // fixme: UAE correction doesn't belong here, fix in map - geoname = geoname.replace(' - United Arab Emirates', ', United Arab Emirates') + geoname = (geoname || '').replace(' - United Arab Emirates', ', United Arab Emirates') return Ox.getCountryByName( geoname.split(', ').pop() .replace('Sint Eustatius and Saba', 'Bonaire, Sint Eustatius and Saba')