Comments (6)
export interface ICommand {
client?: WAClient;
handler?: MessageHandler;
run(
M: ISimplifiedMessage,
parsedArgs: IParsedArgs
): Promise<void | never> | void | never;
config: {
adminOnly?: boolean;
aliases?: string[];
description?: string;
command: string;
id?: string;
category?: TCategory;
usage?: string;
dm?: boolean;
baseXp?: number;
modsOnly?: boolean;
};
}
You can check it here
from chitoge.
Just tell me how to make this command available for admins and mods both!!
Like if there's a admin but it's not mod then he can use it also if there's a mod but not group admin he can also use that command
from chitoge.
Just tell me how to make this command available for admins and mods both!! Like if there's a admin but it's not mod then he can use it also if there's a mod but not group admin he can also use that command
Unfortunately there isn't a config for that. But you can one like this -
if (!this.client.config.mods.includes(M.sender.jid) && !M.sender.isAdmin)
return void M.reply("You can't use this command")
I hope this clears your issue
from chitoge.
Just tell me how to make this command available for admins and mods both!! Like if there's a admin but it's not mod then he can use it also if there's a mod but not group admin he can also use that command
Unfortunately there isn't a config for that. But you can one like this -
if (!this.client.config.mods.includes(M.sender.jid) && !M.sender.isAdmin) return void M.reply("You can't use this command")I hope this clears your issue
You didn't tell me where I need to paste it
So, it's possible I do a mistake
from chitoge.
I think this is what you're looking for
from chitoge.
I think this is what you're looking for
Haha 🙄
Nice, Joke!!
Now tell me where I put that code in This Command
from chitoge.
Related Issues (20)
- Request for new commands and bugs HOT 2
- Features request
- Feature request HOT 1
- Command improvement HOT 2
- Spotify issue
- HOW TO GET SESSION HOT 6
- Heroku Deploy's Issue !! HOT 6
- Application Error HOT 7
- ✨✨ HOT 6
- Error on scanning QR HOT 1
- Bot turn off automatically while using HOT 1
- application crashed HOT 2
- BaileysError: Unexpected error in login HOT 3
- Messagehandler.ts issues HOT 1
- error scan HOT 2
- So, Can you tell me please 🥺
- Harem hunt HOT 1
- nhentai-search not working HOT 1
- WhatsApp QR code Scan Not Working For Real HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from chitoge.