Merge pull request #330 from teloxide/clarify-storage-purpose

Clarify the purpose of Storage in the docs
This commit is contained in:
Waffle Lapkin 2021-03-22 11:13:29 +03:00 committed by GitHub
commit ceeb471294
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -27,6 +27,9 @@ pub use sqlite_storage::{SqliteStorage, SqliteStorageError};
/// You can implement this trait for a structure that communicates with a DB and
/// be sure that after you restart your bot, all the dialogues won't be lost.
///
/// `Storage` is used only to store dialogue states, i.e. it can't be used as a
/// generic database.
///
/// Currently we support the following storages out of the box:
///
/// - [`InMemStorage`] - a storage based on a simple hash map