code: function errorSerializer (err) {
    if (!err || !err.stack) return err
    const obj = {
      message: err.message,
      name: err.name,
      code: err.code,
      stack: getErrorStack(err)
    }
    return obj
  }
docs: Serializes Error Objects
  
  @type {import("pino").SerializerFn}
  @param  {any} err