Add comment regarding configuration options and update changelog.

parent 4cbce0d7
...@@ -7,6 +7,7 @@ Exclamation symbols (:exclamation:) note something of importance e.g. breaking c ...@@ -7,6 +7,7 @@ Exclamation symbols (:exclamation:) note something of importance e.g. breaking c
### Added ### Added
- Callbacks can be added to be executed when callback queries are called. - Callbacks can be added to be executed when callback queries are called.
- New Bot API 3.1 changes (#550). - New Bot API 3.1 changes (#550).
- `/cleanup` command for admins, that cleans out old entries from the DB.
### Changed ### Changed
- [:exclamation:][unreleased-bc-request-class-refactor] Big refactor of the `Request` class, removing most custom method implementations. - [:exclamation:][unreleased-bc-request-class-refactor] Big refactor of the `Request` class, removing most custom method implementations.
### Deprecated ### Deprecated
......
...@@ -19,6 +19,21 @@ use PDOException; ...@@ -19,6 +19,21 @@ use PDOException;
/** /**
* User "/cleanup" command * User "/cleanup" command
*
* Configuration options:
*
* $telegram->setCommandConfig('cleanup', [
* // Define which tables should be cleaned.
* 'tables_to_clean' => [
* 'message',
* 'edited_message',
* ],
* // Define how old cleaned entries should be.
* 'clean_older_than' => [
* 'message' => '7 days',
* 'edited_message' => '30 days',
* ]
* );
*/ */
class CleanupCommand extends AdminCommand class CleanupCommand extends AdminCommand
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment