From b5bd2ffecfec9006f6e4c69be73d5d1852903ca6 Mon Sep 17 00:00:00 2001 From: Mike MacMillan <1801375+mmacmillan@users.noreply.github.com> Date: Mon, 27 Nov 2023 16:20:27 -0800 Subject: [PATCH] serviceCode is being parsed as a number and throwing the exception 'toLowerCase is not a function'; this exception hides the original exception. coercing to string and calling toLowerCase to handle null, numeric, and blank case --- lib/common/lib/error.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/common/lib/error.ts b/lib/common/lib/error.ts index 1df20e3842..a0a01bd230 100644 --- a/lib/common/lib/error.ts +++ b/lib/common/lib/error.ts @@ -24,7 +24,7 @@ export class OciError extends Error { ) { super(message); - const apiErrorsInfo = `See ${TROUBLESHOOT_LINK}#apierrors_${statusCode}__${statusCode}_${serviceCode.toLowerCase()} for more information about resolving this error`; + const apiErrorsInfo = `See ${TROUBLESHOOT_LINK}#apierrors_${statusCode}__${statusCode}_${(serviceCode+'').toLowerCase()} for more information about resolving this error`; const contactInfo = `If you are unable to resolve this ${targetService} issue, please contact Oracle support and provide them this full error message.`; if (apiReferenceLink) {