Change theme
Help
Press space for more information.
Show links for this issue (Shortcut: i, l)
Copy issue ID
Previous Issue (Shortcut: k)
Next Issue (Shortcut: j)
Sign in to use full features.
Vote: I am impacted
Notification menu
Refresh (Shortcut: Shift+r)
Go home (Shortcut: u)
Pending code changes (auto-populated)
Needs more info comment that > 10 days [ID: 963198]
Comment such as: SPAM, non-actionable [ID: 963127]
Resolved actionable follow-up comments [ID: 963027]
View issue level access limits(Press Alt + Right arrow for more information)
Unintended behavior
View staffing
Description
coord.lat()//gives NaN, should give 0
coord.lng()//gives NaN, should give 0
Using it as
coord = new google.maps.LatLng(0, 0)
works fine, both coord.lat() and coord.lng() gives 0 as expected.
Bug is in function google.maps.LatLng, the conditional
if (a && (a.lat || a.lng)) is WRONG,
it should check for
if (a && (!isNaN(a.lat) || !isNaN(a.lng)))
or similar.