fix(striker-ui-api): no response body, unspecific fail assert message in create/update UPS

main
Tsu-ba-me 2 years ago
parent 78d7ce90b9
commit 4bbacab09f
  1. 4
      striker-ui-api/src/lib/request_handlers/ups/createUps.ts

@ -9,7 +9,7 @@ import { stderr, uuid } from '../../shell';
export const createUps: RequestHandler< export const createUps: RequestHandler<
{ uuid?: string }, { uuid?: string },
UpsOverview, undefined,
{ agent: string; ipAddress: string; name: string } { agent: string; ipAddress: string; name: string }
> = async (request, response) => { > = async (request, response) => {
const { const {
@ -43,7 +43,7 @@ export const createUps: RequestHandler<
`UPS UUID must be a valid UUIDv4; got [${upsUuid}]`, `UPS UUID must be a valid UUIDv4; got [${upsUuid}]`,
); );
} catch (error) { } catch (error) {
stderr(`Assert value failed during create UPS; CAUSE: ${error}`); stderr(`Assert value failed when working with UPS; CAUSE: ${error}`);
return response.status(400).send(); return response.status(400).send();
} }

Loading…
Cancel
Save