nestjs-telegraf/lib/decorators/telegraf-use.decorator.ts

12 lines
267 B
TypeScript
Raw Normal View History

2020-03-19 16:34:44 +03:00
import { SetMetadata } from '@nestjs/common';
import { DECORATORS } from '../telegraf.constants';
/**
* Registers a middleware.
*
* https://telegraf.js.org/#/?id=use
*/
export function TelegrafUse(): MethodDecorator {
return SetMetadata(DECORATORS.USE, {});
}