fs: mkdtemp should not fail if no callback passed
Checklist
-
tests and code linting passes -
a test is included -
the commit message follows commit guidelines
Affected core subsystem(s)
fs
Description of change
As it is, fs.mkdtemp
crashes with a C++ assertion if the callback
function is not passed. This patch uses maybeCallback
to create one,
if no callback function is passed.