* Synchronously reads the contents of a symbolic link * referred to by `path`. * @param {string | Buffer | URL} path * @param {{ encoding?: string; } | string} [options] * @returns {string | Buffer}
(path, options)
| 2139 | * @returns {string | Buffer} |
| 2140 | */ |
| 2141 | function readlinkSync(path, options) { |
| 2142 | const h = vfsState.handlers; |
| 2143 | if (h !== null) { |
| 2144 | const result = h.readlinkSync(path, options); |
| 2145 | if (result !== undefined) return result; |
| 2146 | } |
| 2147 | options = getOptions(options); |
| 2148 | return binding.readlink(getValidatedPath(path), options.encoding); |
| 2149 | } |
| 2150 | |
| 2151 | /** |
| 2152 | * Creates the link called `path` pointing to `target`. |
no test coverage detected
searching dependent graphs…