-
-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how to work with multiple bots? #854
Comments
Solved it by dividing into 2 modules: |
@Daniyar111 , Hi! Could you share a more detailed code of your main app.module and AdminBotModule? I trying add a second Bot to my app, but it doesn't work :( |
@lasthead Hi! app.module.ts:
client-bot.module.ts:
admin-bot.module.ts:
|
@Daniyar111 , many thanks! However, I don't quite understand what to specify in middleware to divided requests from each other? For example: in app2.app.update.ts i have the same method and they conflict with each other I think I misunderstand the concept and... maybe this check needs to be implemented inside the app.update.ts |
@lasthead If you did
Nothing need to add there.. I added just sessions to middleware, it doesn't affect to requests
no check needed.. just divide your code structure to
So they must work independent of each other |
@Daniyar111 , After your comment, I rechecked my code again and... found my error. I just missed row: |
I have 2 bots which are initialized in
app.module.ts
:And I have
bot.module.ts
which isand it should work with
@Update() class
withadmin.update.ts
andclient.update.ts
:but there is no answer in bots. If I change
BotModule
tois working just with
admin.update.ts
The text was updated successfully, but these errors were encountered: