diff options
| author | Austin Hellyer <[email protected]> | 2016-10-23 15:25:57 -0700 |
|---|---|---|
| committer | Austin Hellyer <[email protected]> | 2016-10-23 15:25:57 -0700 |
| commit | 517076461cd772f92a20925fff0b748df363ac6b (patch) | |
| tree | 9102210e56958a1b8ff3cd7d2b7a57e0f32a9894 /README.md | |
| parent | Abstract opcodes to enums (diff) | |
| download | serenity-517076461cd772f92a20925fff0b748df363ac6b.tar.xz serenity-517076461cd772f92a20925fff0b748df363ac6b.zip | |
Fix readme example to properly use framework
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -50,8 +50,8 @@ use serenity::Client; fn main() { // Login with a bot token from the environment let client = Client::login_bot(env::var("DISCORD_TOKEN").expect("token")); - client.with_framework(|c| c - .prefix("~") // set the bot's prefix to '~' + client.with_framework(|f| f + .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 |