| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -77,7 +77,7 @@ class TupleOrigin { | |||
| 77 | 77 | return result; | |
| 78 | 78 | } | |
| 79 | 79 | ||
| 80 | - inspect() { | ||
| 80 | + [util.inspect.custom]() { | ||
| 81 | 81 | return `TupleOrigin { | |
| 82 | 82 | scheme: ${this[kScheme]}, | |
| 83 | 83 | host: ${this[kHost]}, | |
@@ -235,7 +235,7 @@ class URL { | |||
| 235 | 235 | return (this[context].flags & binding.URL_FLAGS_CANNOT_BE_BASE) !== 0; | |
| 236 | 236 | } | |
| 237 | 237 | ||
| 238 | - inspect(depth, opts) { | ||
| 238 | + [util.inspect.custom](depth, opts) { | ||
| 239 | 239 | const ctx = this[context]; | |
| 240 | 240 | var ret = 'URL {\n'; | |
| 241 | 241 | ret += ` href: ${this.href}\n`; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,6 +1,7 @@ | |||
| 1 | 1 | 'use strict'; | |
| 2 | 2 | ||
| 3 | 3 | const common = require('../common'); | |
| 4 | + const util = require('util'); | ||
| 4 | 5 | ||
| 5 | 6 | if (!common.hasIntl) { | |
| 6 | 7 | // A handful of the tests fail when ICU is not included. | |
@@ -144,8 +145,8 @@ for (const test of allTests) { | |||
| 144 | 145 | const url = test.url ? new URL(test.url) : new URL(test.input, test.base); | |
| 145 | 146 | ||
| 146 | 147 | for (const showHidden of [true, false]) { | |
| 147 | - const res = url.inspect(null, { | ||
| 148 | - showHidden: showHidden | ||
| 148 | + const res = util.inspect(url, { | ||
| 149 | + showHidden | ||
| 149 | 150 | }); | |
| 150 | 151 | ||
| 151 | 152 | const lines = res.split('\n'); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments