-
-
Notifications
You must be signed in to change notification settings - Fork 9
Custom Trainername #28
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -49,3 +49,8 @@ | |
| sendMessage($update['message']['chat']['id'], '<b>' . getTranslation('not_supported') . '</b>'); | ||
| } | ||
| } | ||
| // IF a Message type is private and there is no leading '/' | ||
| else if($update['message']['chat']['type'] == 'private'){ | ||
| // Get Message from User sent to Bot and check what to do | ||
| evaluate_priv_message($update); | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since this function is not available in this project this will fail if not implemented in all bots dependent on the core. |
||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to clarify, we're not evaluating a command but a reply to a command?
Telegram has built in functionality for getting responses, could we not use that: https://core.telegram.org/bots/api#forcereply ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really like that idea! @Artanicus
This way we would not need a trainername_time database field at all 😁
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're not really built for using forceReply efficiently so I'll do some plumbing in
telegram/functions.phpto generalize the$inline_keyboardto a$reply_markuparray.