Skip to content

Commit

Permalink
rebuilt after merging PR #81
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielJDufour committed Jan 5, 2025
1 parent aa41138 commit 9d8341f
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion dist/mgrs.esm.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/mgrs.esm.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/mgrs.js
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@
*/
function inverse(mgrs) {
const bbox = UTMtoLL(decode(mgrs.toUpperCase()));
if (bbox.lat && bbox.lon) {
if (typeof bbox.lat === 'number' && typeof bbox.lon === 'number') {
return [bbox.lon, bbox.lat, bbox.lon, bbox.lat];
}
return [bbox.left, bbox.bottom, bbox.right, bbox.top];
Expand All @@ -133,7 +133,7 @@
throw new TypeError('toPoint received a blank string');
}
const bbox = UTMtoLL(decode(mgrs.toUpperCase()));
if (bbox.lat && bbox.lon) {
if (typeof bbox.lat === 'number' && typeof bbox.lon === 'number') {
return [bbox.lon, bbox.lat];
}
return [(bbox.left + bbox.right) / 2, (bbox.top + bbox.bottom) / 2];
Expand Down
Loading

0 comments on commit 9d8341f

Please sign in to comment.