Commits

Jon Nylander  committed 9ee73ff

Continuing work on integrating both IP and geolocation API - questions remain. Should geolocation take precedence over javascript results. IP results should definitely not.

  • Participants
  • Parent commits 560aca0
  • Branches Experimenting with IP lookups for more exactness

Comments (0)

Files changed (1)

File detect_timezone.js

         },
         
         tz_lookup_callback = function (ip_timezone_data) {
-            if (ip_timezone_data.timezone !== preliminary_result.name()) {
-                preliminary_result.compare_with(ip_timezone_data);
-                config.callback(preliminary_result);
-                return;
+            if (ip_timezone_data) {
+                if (ip_timezone_data.timezone !== preliminary_result.name()) {
+                    preliminary_result.compare_with(ip_timezone_data);
+                }
             }
             config.callback(preliminary_result);
         },