* Synchronously creates a unique temporary directory. * @param {string | Buffer | URL} prefix * @param {string | { encoding?: string; }} [options] * @returns {string}
(prefix, options)
| 3587 | * @returns {string} |
| 3588 | */ |
| 3589 | function mkdtempSync(prefix, options) { |
| 3590 | const h = vfsState.handlers; |
| 3591 | if (h !== null) { |
| 3592 | const result = h.mkdtempSync(prefix, options); |
| 3593 | if (result !== undefined) return result; |
| 3594 | } |
| 3595 | |
| 3596 | options = getOptions(options); |
| 3597 | |
| 3598 | prefix = getValidatedPath(prefix, 'prefix'); |
| 3599 | warnOnNonPortableTemplate(prefix); |
| 3600 | return binding.mkdtemp(prefix, options.encoding); |
| 3601 | } |
| 3602 | |
| 3603 | /** |
| 3604 | * Synchronously creates a unique temporary directory. |
no test coverage detected
searching dependent graphs…