mirror of
https://github.com/maciejpedzich/six-degs-of-f1.git
synced 2024-11-27 15:55:47 +01:00
Compare commits
3 Commits
98711d228b
...
4add5754b6
Author | SHA1 | Date | |
---|---|---|---|
4add5754b6 | |||
7539e93430 | |||
3aa6a9d3f8 |
@ -25,7 +25,7 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- db
|
- db
|
||||||
db:
|
db:
|
||||||
image: memgraph/memgraph:2.18.1
|
image: memgraph/memgraph:2.19.0
|
||||||
container_name: sixdegs-db
|
container_name: sixdegs-db
|
||||||
hostname: sixdegs-db
|
hostname: sixdegs-db
|
||||||
networks:
|
networks:
|
||||||
|
1629
data/drivers.csv
1629
data/drivers.csv
File diff suppressed because it is too large
Load Diff
@ -5002,3 +5002,4 @@ driverId,teammateId
|
|||||||
784,788
|
784,788
|
||||||
826,843
|
826,843
|
||||||
849,851
|
849,851
|
||||||
|
848,861
|
||||||
|
|
1924
package-lock.json
generated
1924
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
10
package.json
10
package.json
@ -10,14 +10,14 @@
|
|||||||
"astro": "astro"
|
"astro": "astro"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@astrojs/node": "^8.2.5",
|
"@astrojs/node": "^8.3.3",
|
||||||
"astro": "^4.4.14",
|
"astro": "^4.15.1",
|
||||||
"neo4j-driver": "^5.18.0"
|
"neo4j-driver": "^5.24.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@astrojs/check": "^0.5.6",
|
"@astrojs/check": "^0.9.3",
|
||||||
"@picocss/pico": "^2.0.6",
|
"@picocss/pico": "^2.0.6",
|
||||||
"typescript": "^5.4.2",
|
"typescript": "^5.5.4",
|
||||||
"vis-network": "^9.1.9"
|
"vis-network": "^9.1.9"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -22,8 +22,14 @@ let graphProps: Awaited<ReturnType<typeof getShortestPaths>> = {
|
|||||||
try {
|
try {
|
||||||
driverNames = await getDriverNames();
|
driverNames = await getDriverNames();
|
||||||
|
|
||||||
if (noEmptyParams && paramsNotEqual)
|
if (noEmptyParams && paramsNotEqual) {
|
||||||
|
const timestamp = new Date().toLocaleString('pl');
|
||||||
|
const clientIp =
|
||||||
|
Astro.request.headers.get('X-Forwarded-For') || Astro.clientAddress;
|
||||||
|
|
||||||
|
console.log(`[${timestamp}] ${clientIp} FROM ${source} TO ${dest}`);
|
||||||
graphProps = await getShortestPaths(source, dest);
|
graphProps = await getShortestPaths(source, dest);
|
||||||
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
return Astro.redirect('/error');
|
return Astro.redirect('/error');
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user