@yamdbf/command-usage
Version:
YAMDBF plugin for logging command usage and command usage statistics
22 lines (19 loc) • 499 B
text/typescript
import { Client, Logger } from '@yamdbf/core';
import { commandUsage } from '../bin/';
const config: any = require('./config.json');
const logger: Logger = Logger.instance();
class Test extends Client
{
public constructor()
{
super({
token: config.token,
owner: config.owner,
readyText: 'Test client ready',
plugins: [commandUsage(config.commandLog)]
});
}
}
const test: Test = new Test();
test.start();
process.on('unhandledRejection', (err: any) => logger.error(err) as any);