diff --git a/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/common/validator.js b/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/common/validator.js index 47b53f57c29655528632b43633d6169953a905ad..633f65003d25928f4d46c4639adec73ab7f3a72c 100644 --- a/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/common/validator.js +++ b/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/common/validator.js @@ -166,7 +166,7 @@ function checkClientInfo (clientInfo) { } const numberNotRequired = { required: false, - type: 'string' + type: 'number' } const schema = { uniPlatform: 'string', @@ -200,7 +200,7 @@ function checkClientInfo (clientInfo) { console.warn('- 如果使用HBuilderX运行本地云函数/云对象功能时出现此提示,请改为使用客户端调用本地云函数方式调试,或更新HBuilderX到3.4.12及以上版本。\n- 如果是缺少clientInfo.appId,请检查项目manifest.json内是否配置了DCloud AppId') throw new Error(`"clientInfo.${validateRes.schemaKey}" is required.`) } else { - throw new Error('Invalid client info') + throw new Error(`Invalid client info: clienInfo.${validateRes.schemaKey}`) } } }