forked from ppfun/pixelplanet
allow links with zoom in coords field
This commit is contained in:
parent
1da5d130c6
commit
b39125fbfb
|
@ -484,7 +484,7 @@ export function coordsFromString(url) {
|
||||||
if (splitInd !== -1) {
|
if (splitInd !== -1) {
|
||||||
part = part.slice(0, splitInd);
|
part = part.slice(0, splitInd);
|
||||||
}
|
}
|
||||||
coords = part.split(',').map((z) => parseInt(z, 10)).slice(1);
|
coords = part.split(',').map((z) => parseInt(z, 10)).slice(1, 3);
|
||||||
}
|
}
|
||||||
if (coords.length !== 2 || coords.some(Number.isNaN)) {
|
if (coords.length !== 2 || coords.some(Number.isNaN)) {
|
||||||
coords = url.split('_').map((z) => parseInt(z, 10));
|
coords = url.split('_').map((z) => parseInt(z, 10));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user