1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-21 23:04:45 -05:00

refactor(ext/console): align error messages (#25301)

Aligns the error messages in the console extension to be in-line with
the Deno style guide.

https://github.com/denoland/deno/issues/25269
This commit is contained in:
Ian Bull 2024-09-02 07:28:17 -07:00 committed by GitHub
parent a3bd1ba26d
commit 977f8137f3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -179,7 +179,7 @@ class AssertionError extends Error {
}
}
function assert(cond, msg = "Assertion failed.") {
function assert(cond, msg = "Assertion failed") {
if (!cond) {
throw new AssertionError(msg);
}
@ -3236,8 +3236,8 @@ class Console {
table = (data = undefined, properties = undefined) => {
if (properties !== undefined && !ArrayIsArray(properties)) {
throw new Error(
"The 'properties' argument must be of type Array. " +
"Received type " + typeof properties,
"The 'properties' argument must be of type Array: " +
"received type " + typeof properties,
);
}