Skip to content

Commit

Permalink
fix(api): adjust GraphQL query syntax to match enum representation
Browse files Browse the repository at this point in the history
  • Loading branch information
Robert27 committed Nov 2, 2024
1 parent 81c6c2e commit 9b4d193
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions rogue-thi-app/data/mobility.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@
"train": {
"defaultStation": "nord",
"stations": [
{ "id": "nord", "name": "Nordbahnhof" },
{ "id": "hbf", "name": "Hauptbahnhof" },
{ "id": "audi", "name": "Audi" }
{ "id": "INGOLSTADT_NORD", "name": "Nordbahnhof" },
{ "id": "NGOLSTADT_HBF", "name": "Hauptbahnhof" },
{ "id": "NGOLSTADT_AUDI", "name": "Audi" }
]
},
"parking": [
Expand Down
6 changes: 3 additions & 3 deletions rogue-thi-app/lib/backend/neuland-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class NeulandAPIClient {
return await this.performGraphQLQuery(
gql`
query {
food(locations: [${locations.map((x) => `"${x}"`).join(',')}]) {
food(locations: [${locations.join(',')}]) {
errors {
location
message
Expand Down Expand Up @@ -128,7 +128,7 @@ class NeulandAPIClient {
return this.performGraphQLQuery(
gql`
query {
bus(station: "${station}") {
bus(station: ${station}) {
route
destination
time
Expand All @@ -145,7 +145,7 @@ class NeulandAPIClient {
return this.performGraphQLQuery(
gql`
query {
train(station: "${station}") {
train(station: ${station}) {
name
destination
plannedTime
Expand Down

0 comments on commit 9b4d193

Please sign in to comment.