ERR_MISSING_ARGS
未传入 Node.js API 的必需参数。
这仅用于严格遵守 API 规范(在某些情况下可能接受 func(undefined)
但不接受 func()
)。
在大多数原生 Node.js API 中,func(undefined)
和 func()
的处理方式相同,可以使用 ERR_INVALID_ARG_TYPE
错误码代替。
A required argument of a Node.js API was not passed. This is only used for
strict compliance with the API specification (which in some cases may accept
func(undefined)
but not func()
). In most native Node.js APIs,
func(undefined)
and func()
are treated identically, and the
ERR_INVALID_ARG_TYPE
error code may be used instead.