mirror of
https://github.com/nodejs/node.git
synced 2024-11-21 10:59:27 +00:00
assert: remove deprecated getFunction() usage
The method is meant to be removed by the V8 team. It is not a critical functionality that is removed, therefore no alternative is checked for either. Refs: https://bugs.chromium.org/p/v8/issues/detail?id=9421 Signed-off-by: Ruben Bridgewater <ruben@bridgewater.de> PR-URL: https://github.com/nodejs/node/pull/46661 Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com> Reviewed-By: Ujjwal Sharma <ryzokuken@disroot.org> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
parent
6bc87b71fd
commit
43c380e9b6
@ -308,12 +308,7 @@ function getErrMessage(message, fn) {
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
const fn = call.getFunction();
|
||||
if (!fn) {
|
||||
return message;
|
||||
}
|
||||
code = String(fn);
|
||||
identifier = `${code}${line}${column}`;
|
||||
return message;
|
||||
}
|
||||
|
||||
if (errorCache.has(identifier)) {
|
||||
|
@ -921,7 +921,7 @@ assert.throws(
|
||||
{
|
||||
code: 'ERR_ASSERTION',
|
||||
constructor: assert.AssertionError,
|
||||
message: 'The expression evaluated to a falsy value:\n\n assert(1 === 2)\n'
|
||||
message: 'false == true'
|
||||
}
|
||||
);
|
||||
assert.throws(
|
||||
|
Loading…
Reference in New Issue
Block a user