diff options
| author | Austin Hellyer <[email protected]> | 2016-11-06 10:17:08 -0800 |
|---|---|---|
| committer | Austin Hellyer <[email protected]> | 2016-11-06 10:17:08 -0800 |
| commit | 8f145f223804b869df2304a64ce5d3d42c772226 (patch) | |
| tree | 285a7c187c876f9acd1eaf5c7031704209bcf01e /src/lib.rs | |
| parent | Move HTTP/ratelimiting into a separate module (diff) | |
| download | serenity-8f145f223804b869df2304a64ce5d3d42c772226.tar.xz serenity-8f145f223804b869df2304a64ce5d3d42c772226.zip | |
Add some more documentation
Diffstat (limited to 'src/lib.rs')
| -rw-r--r-- | src/lib.rs | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -44,13 +44,13 @@ //! extern crate serenity; //! //! use serenity::Client; +//! use std::env; //! //! fn main() { //! // Login with a bot token from the environment -//! let client = Client::login_bot(env::var("DISCORD_TOKEN").expect("token")); +//! let mut client = Client::login_bot(&env::var("DISCORD_TOKEN").expect("token")); //! client.with_framework(|f| f -//! .configure(|c| c.prefix("~")) // set the bot's prefix to "~" -//! .prefix("~") +//! .configure(|c| c.prefix("~")) // set the bot's prefix to '~' //! .on("ping", |_context, message| drop(message.reply("Pong!")))); //! //! let _ = client.start(); // start listening for events by starting a connection |