Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

only suggest cities starting with query

Abhinav759d973b3a66
diff --git a/apps/photos/src/services/locationSearchService.ts b/apps/photos/src/services/locationSearchService.ts
index a32ac6f137..2e91ce8842 100644
--- a/apps/photos/src/services/locationSearchService.ts
+++ b/apps/photos/src/services/locationSearchService.ts
@@ -33,7 +33,7 @@ class LocationSearchService {
}
await this.citiesPromise;
return this.cities.filter((city) => {
- return city.city.toLowerCase().includes(searchTerm.toLowerCase());
+ return city.city.toLowerCase().startsWith(searchTerm.toLowerCase());
});
}
}