update method signatures to not include system id

This commit is contained in:
2025-04-07 19:17:14 -07:00
parent 0076d987ca
commit b6f3e4ccde
7 changed files with 46 additions and 47 deletions

View File

@@ -24,7 +24,7 @@ export const ShuttleResolvers: Resolvers<ServerContext> = {
const system = contextValue.findSystemById(parent.systemId);
if (!system) return null;
const etasForShuttle = await system.shuttleRepository.getEtas(parent.id);
const etasForShuttle = await system.shuttleRepository.getEtasForShuttleId();
if (!etasForShuttle) return null;
const computedEtas = await Promise.all(etasForShuttle.map(async ({

View File

@@ -9,7 +9,7 @@ export const SystemResolvers: Resolvers<ServerContext> = {
return [];
}
return await system.shuttleRepository.getRoutes(parent.id);
return await system.shuttleRepository.getRoutes();
},
stops: async (parent, _args, contextValue, _info) => {
const system = contextValue.findSystemById(parent.id);
@@ -17,7 +17,7 @@ export const SystemResolvers: Resolvers<ServerContext> = {
return [];
}
return await system.shuttleRepository.getStops(parent.id);
return await system.shuttleRepository.getStops();
},
stop: async (parent, args, contextValue, _info) => {
if (!args.id) return null;
@@ -76,7 +76,7 @@ export const SystemResolvers: Resolvers<ServerContext> = {
return [];
}
return await system.shuttleRepository.getShuttles(parent.id);
return await system.shuttleRepository.getShuttles();
}
},
}