diff --git a/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/lib/utils/sms.js b/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/lib/utils/sms.js index 1f45a7004c436ae66b7335685490020047b05363..21c70e9c6c49a6aed98f0f5542a7c811e1a2da92 100644 --- a/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/lib/utils/sms.js +++ b/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/lib/utils/sms.js @@ -45,7 +45,7 @@ async function sendSmsCode ({ action = this.t('verify-mobile') break } - const sceneConfig = smsConfig.scene || {} + const sceneConfig = (smsConfig.scene || {})[scene] || {} if (!templateId) { templateId = sceneConfig.templateId } diff --git a/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/package.json b/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/package.json index ebce79811ae991f5e2c85e21054e3cdc0967846f..f918c2657d779b17e79925bb290471061a9af8c5 100644 --- a/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/package.json +++ b/uni_modules/uni-id-pages/uniCloud/cloudfunctions/uni-id-co/package.json @@ -13,5 +13,7 @@ "uni-id-common": "file:../../../../uni-id-common/uniCloud/cloudfunctions/common/uni-id-common", "uni-open-bridge-common": "file:../../../../uni-open-bridge-common/uniCloud/cloudfunctions/common/uni-open-bridge-common" }, - "extensions": {} -} + "extensions": { + "uni-cloud-sms": {} + } +} \ No newline at end of file