liuyu 4 年之前
父节点
当前提交
e824516b9f
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      app/service/roomuser.js

+ 1 - 0
app/service/roomuser.js

@@ -84,6 +84,7 @@ class RoomuserService extends CrudService {
     const { name, phone, openid } = data;
     assert(name, '用户名不能为空');
     assert(phone, '电话号码不能为空');
+    assert(openid, '微信openid不能为空');
     const has_phone = await this.model.findOne({ phone });
     if (has_phone) {
       throw new BusinessError('此手机号已被注册,请更换手机号');