You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.1 KiB

1 year ago
  1. <?php
  2. /**
  3. * This file is part of the PHP Telegram Bot example-bot package.
  4. * https://github.com/php-telegram-bot/example-bot/
  5. *
  6. * (c) PHP Telegram Bot Team
  7. *
  8. * For the full copyright and license information, please view the LICENSE
  9. * file that was distributed with this source code.
  10. */
  11. namespace Longman\TelegramBot\Commands\SystemCommands;
  12. use Longman\TelegramBot\Commands\SystemCommand;
  13. use Longman\TelegramBot\Entities\ServerResponse;
  14. /**
  15. * Edited message command
  16. *
  17. * Gets executed when a user message is edited.
  18. */
  19. class EditedmessageCommand extends SystemCommand
  20. {
  21. /**
  22. * @var string
  23. */
  24. protected $name = 'editedmessage';
  25. /**
  26. * @var string
  27. */
  28. protected $description = 'Handle edited message';
  29. /**
  30. * @var string
  31. */
  32. protected $version = '1.2.0';
  33. /**
  34. * Main command execution
  35. *
  36. * @return ServerResponse
  37. */
  38. public function execute(): ServerResponse
  39. {
  40. // Get the edited message
  41. $edited_message = $this->getEditedMessage();
  42. return parent::execute();
  43. }
  44. }