You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I can match the updates by their type first (all messages, replies, reactions, joins) and then do inner match for each (e.g. for messages, what command it contains), but I would like to split them based on what functionality they provide, not what type they are.
Additional context
I wonder if its possible without any changes to the library and only using the Match type somehow? I tried it but couldn't get the types right:
Is your feature request related to a problem? Please describe.
I'm making a telegram bot and the main part of it is a function like this (I'm not using any library, just typed jsons):
Describe the solution you'd like
I wish there was a way to split the long match block into smaller parts. For example:
#209 could improve the api further.
Describe alternatives you've considered
I can match the updates by their type first (all messages, replies, reactions, joins) and then do inner match for each (e.g. for messages, what command it contains), but I would like to split them based on what functionality they provide, not what type they are.
Additional context
I wonder if its possible without any changes to the library and only using the
Match
type somehow? I tried it but couldn't get the types right:Maybe exporting some helper types for this use case would be enough.
The text was updated successfully, but these errors were encountered: