chz-telegram-bot 0.3.19 → 0.3.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entities/actions/commandAction.js +1 -1
- package/entities/actions/commandAction.ts +1 -1
- package/package.json +1 -1
- /package/dist/dtos/{ActionPermissionsData.d.ts → actionPermissionsData.d.ts} +0 -0
- /package/dist/dtos/{ActionPermissionsData.d.ts.map → actionPermissionsData.d.ts.map} +0 -0
- /package/dist/dtos/{ActionPermissionsData.js → actionPermissionsData.js} +0 -0
|
@@ -87,7 +87,7 @@ class CommandAction {
|
|
|
87
87
|
if (!this.active)
|
|
88
88
|
return commandTriggerCheckResult_1.CommandTriggerCheckResult.DontTriggerAndSkipCooldown('ActionDisabled');
|
|
89
89
|
const isChatInBlacklist = this.chatsBlacklist.includes(ctx.chatInfo.id);
|
|
90
|
-
const isChatInWhitelist = this.chatsWhitelist.length
|
|
90
|
+
const isChatInWhitelist = this.chatsWhitelist.length == 0 ||
|
|
91
91
|
this.chatsWhitelist.includes(ctx.chatInfo.id);
|
|
92
92
|
if (isChatInBlacklist || !isChatInWhitelist)
|
|
93
93
|
return commandTriggerCheckResult_1.CommandTriggerCheckResult.DontTriggerAndSkipCooldown('ChatForbidden');
|
|
@@ -155,7 +155,7 @@ export class CommandAction<TActionState extends IActionState>
|
|
|
155
155
|
|
|
156
156
|
const isChatInBlacklist = this.chatsBlacklist.includes(ctx.chatInfo.id);
|
|
157
157
|
const isChatInWhitelist =
|
|
158
|
-
this.chatsWhitelist.length
|
|
158
|
+
this.chatsWhitelist.length == 0 ||
|
|
159
159
|
this.chatsWhitelist.includes(ctx.chatInfo.id);
|
|
160
160
|
|
|
161
161
|
if (isChatInBlacklist || !isChatInWhitelist)
|
package/package.json
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|