Просмотр исходного кода

BugFix: count SlackAppIntegration

Yuki Takei 4 лет назад
Родитель
Сommit
39dce3a2e2
1 измененных файлов с 2 добавлено и 1 удалено
  1. 2 1
      src/server/routes/apiv3/slack-integration.js

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

@@ -25,10 +25,11 @@ module.exports = (crowi) => {
       return res.status(400).send({ message });
     }
 
-    const slackAppIntegrationCount = await SlackAppIntegration.estimatedDocumentCount({ tokenPtoG });
+    const slackAppIntegrationCount = await SlackAppIntegration.countDocuments({ tokenPtoG });
 
     logger.debug('verifyAccessTokenFromProxy', {
       tokenPtoG,
+      slackAppIntegrationCount,
     });
 
     if (slackAppIntegrationCount === 0) {