(req: Request)
| 8 | |
| 9 | // if req.query.client does not contain a valid client type, then return undefined so it won't filter the nodes unnecessarily |
| 10 | const parseClientParam = (req: Request): ClientType | undefined => { |
| 11 | const raw = req.query.client as ClientType | undefined |
| 12 | return raw && VALID_CLIENT_TYPES.has(raw) ? (raw as ClientType) : undefined |
| 13 | } |
| 14 | |
| 15 | const getAllNodes = async (req: Request, res: Response, next: NextFunction) => { |
| 16 | try { |
no outgoing calls
no test coverage detected