From 1cfa73c52ddf69f0c7a580f1ce0e10a62a938225 Mon Sep 17 00:00:00 2001 From: leonnicolas Date: Thu, 17 Dec 2020 14:05:25 +0100 Subject: [PATCH] fix copy bike return -1 as id, so lending station will always be empty because no bike has id -1. --- README.md | 2 +- src/datasources/db/cargobikeAPI.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index cd25810..e5030d5 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,7 @@ The following environment variables can be used to configure the server: ```bash RPC_HOST=host:port NODE_ENV=develop/production -POSTGRES_CONNECTION_URL=postgres://username:password@host:port/database_name +DATABASE_URL=postgres://username:password@host:port/database_name ``` - __RPC_HOST__ is used for the connection with the [flotte-user-management server](https://github.com/fLotte-meets-HWR-DB/flotte-user-management). - __NODE_ENV__ will not check authentication if set to development diff --git a/src/datasources/db/cargobikeAPI.ts b/src/datasources/db/cargobikeAPI.ts index 8f1616f..41d9867 100644 --- a/src/datasources/db/cargobikeAPI.ts +++ b/src/datasources/db/cargobikeAPI.ts @@ -565,6 +565,7 @@ export class CargoBikeAPI extends DataSource { delete cargoBike[value.key]; } }); + cargoBike.id = -1; return cargoBike; }