云函数数据更新失败
发布于 6 年前 作者 byang 16998 次浏览 来自 问答
  • 当前 Bug 的表现(可附上截图)
async function _Test(e) {
  let $gid = {
    'abc': '456789',
    'bcd': '456789'
  };
  let $data = await db.collection('iTest').doc(e.userInfo.openId).update({
    data: {
      style: _.set($gid)
    }
  });
  return $data;
}

得到结果:

,更新成功

async function _Test(e) {
  let $gid = {
    'abc': '456789',
    'bcd': '456789'
  };
  await db.collection('iTest').doc(e.userInfo.openId).update({
    data: {
      style: _.set($gid)
    }
  }).then(res=>{
    return res;
  })
}

得到结果:

,更新失败

2 回复

同样的问题。add很正常,但update却提示成功,但并未正真更新,请问这是什么科学道理?

刷新就回不来了

回到顶部