@@ -6,7 +6,6 @@ import {GTFS_GRAPHQL_PREFIX} from '../../common/constants'
66import { getGtfsSpec } from '../../common/util/config'
77import { routeSearch , stopSearch } from '../util/graphql'
88import { getHeaders } from '../../common/util/util'
9-
109import type { GtfsRoute , GtfsStop , User } from '../../types'
1110
1211export function getEntityIdField ( type : string ) : string {
@@ -229,6 +228,8 @@ export function searchEntitiesWithString (
229228 const includeStopSubQuery = ! ! filterByRoute
230229 // Build routes/stops query based on entities searching and whether we're
231230 // filtering by a specific route or stop ID.
231+ // FIXME: Removed the hardcoded limit of 30 on the route search so it works with the GTFS_ROUTE_NOT_ADDED field,
232+ // but does removing that negatively affect anything else?
232233 const body = JSON . stringify ( {
233234 query : `
234235query (
@@ -239,7 +240,7 @@ query (
239240) {
240241 feed(namespace: $namespace) {
241242 ${ queryForRoutes && includeRouteSubQuery ? stopSearch ( true , 30 ) : '' }
242- ${ queryForRoutes && ! includeRouteSubQuery ? routeSearch ( false , 30 ) : '' }
243+ ${ queryForRoutes && ! includeRouteSubQuery ? routeSearch ( false ) : '' }
243244 ${ queryForStops && includeStopSubQuery ? routeSearch ( true , 30 ) : '' }
244245 ${ queryForStops && ! includeStopSubQuery ? stopSearch ( false , 30 ) : '' }
245246 }
0 commit comments