Skip to content

Commit

Permalink
use getErrorMessage
Browse files Browse the repository at this point in the history
  • Loading branch information
stanislav-atr committed Mar 22, 2024
1 parent 83bc900 commit c60eb64
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/scriptlets/trusted-suppress-native-method.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {
isValueMatched,
getAbortFunc,
matchStackTrace,
getErrorMessage,
// following helpers should be imported and injected
// because they are used by helpers above
shouldAbortInlineOrInjectedScript,
Expand Down Expand Up @@ -123,7 +124,7 @@ export function TrustedSuppressNativeMethod(
return value === IGNORE_ARG_SYMBOL ? value : inferValue(value);
});
} catch (e) {
logMessage(source, `Could not parse the signature matcher: ${e}`);
logMessage(source, `Could not parse the signature matcher: ${getErrorMessage(e)}`);
return;
}

Expand Down Expand Up @@ -215,6 +216,7 @@ TrustedSuppressNativeMethod.injections = [
isValueMatched,
getAbortFunc,
matchStackTrace,
getErrorMessage,
// following helpers should be imported and injected
// because they are used by helpers above
shouldAbortInlineOrInjectedScript,
Expand Down

0 comments on commit c60eb64

Please sign in to comment.