Add OsmFeature type

This commit is contained in:
Pieter Vander Vennet 2022-07-13 17:56:10 +02:00
parent 284951f5f7
commit 24f090c92f
7 changed files with 26 additions and 20 deletions

View file

@ -159,7 +159,7 @@ export class Changes {
const recentLocationPoints = locations.map(ff => ff.feature)
.filter(feat => feat.geometry.type === "Point")
.filter(feat => {
const visitTime = new Date((<GeoLocationPointProperties>feat.properties).date)
const visitTime = new Date((<GeoLocationPointProperties><any>feat.properties).date)
// In seconds
const diff = (now.getTime() - visitTime.getTime()) / 1000
return diff < Constants.nearbyVisitTime;