Skip to content

Commit

Permalink
Fix Crash for Line Agency Lookup
Browse files Browse the repository at this point in the history
  • Loading branch information
consindo committed Mar 29, 2017
1 parent 60d4b3a commit 1f9f883
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion server/line.js
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,11 @@ function cacheOperatorsAndShapes() {
console.warn(error)
}
// query was successful
lineOperators[todo[index]] = result.entries[0].agency_id._
if (result.entries.length > 0) {
lineOperators[todo[index]] = result.entries[0].agency_id._
} else {
console.warn('could not find agency for', todo[index])
}
getOperator(index + 1)
})

Expand Down

0 comments on commit 1f9f883

Please sign in to comment.