瀏覽代碼

added validation

Steven Fukase 5 年之前
父節點
當前提交
9df6a62c6b
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/server/routes/apiv3/slack-integration-settings.js

+ 1 - 1
src/server/routes/apiv3/slack-integration-settings.js

@@ -71,7 +71,7 @@ module.exports = (crowi) => {
       body('slackappintegrationsId').isMongoId(),
       body('slackappintegrationsId').isMongoId(),
     ],
     ],
     deleteIntegration: [
     deleteIntegration: [
-      query('integrationIdToDelete').isMongoId(),
+      query('integrationIdToDelete').isMongoId().not().isEmpty(),
     ],
     ],
     SlackChannel: [
     SlackChannel: [
       body('channel').trim().not().isEmpty()
       body('channel').trim().not().isEmpty()