mirror of
https://github.com/pezkuwichain/pezkuwi-telemetry.git
synced 2026-04-30 00:17:59 +00:00
Fix location
This commit is contained in:
+2
-2
@@ -6,8 +6,8 @@ declare module 'iplocation' {
|
||||
country?: string;
|
||||
countryCode?: string;
|
||||
isp?: string;
|
||||
lat: number;
|
||||
lon: number;
|
||||
latitude: number;
|
||||
longitude: number;
|
||||
org?: string;
|
||||
query?: string;
|
||||
region?: string;
|
||||
|
||||
@@ -30,7 +30,7 @@ export async function locate(ip: string): Promise<Maybe<Location>> {
|
||||
return resolve(null);
|
||||
}
|
||||
|
||||
const { lat, lon } = result;
|
||||
const { latitude: lat, longitude: lon } = result;
|
||||
const location = { lat, lon } as Location;
|
||||
|
||||
cache.set(ip, location);
|
||||
|
||||
Reference in New Issue
Block a user