{"version":3,"file":"assertValidationError.mjs","sources":["../../../../src/errors/utils/assertValidationError.ts"],"sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { PredictionsError } from '../PredictionsError';\nimport { validationErrorMap, } from '../types/validation';\nexport function assertValidationError(assertion, name) {\n    if (!assertion) {\n        const { message, recoverySuggestion } = validationErrorMap[name];\n        throw new PredictionsError({ name, message, recoverySuggestion });\n    }\n}\n"],"names":[],"mappings":";;;AAAA;AACA;AAGO,SAAS,qBAAqB,CAAC,SAAS,EAAE,IAAI,EAAE;AACvD,IAAI,IAAI,CAAC,SAAS,EAAE;AACpB,QAAQ,MAAM,EAAE,OAAO,EAAE,kBAAkB,EAAE,GAAG,kBAAkB,CAAC,IAAI,CAAC;AACxE,QAAQ,MAAM,IAAI,gBAAgB,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,kBAAkB,EAAE,CAAC;AACzE,IAAI;AACJ;;;;"}