diff options
| author | Nathan Perry <avaglir@gmail.com> | 2018-02-14 12:55:23 -0500 |
|---|---|---|
| committer | Nathan Perry <avaglir@gmail.com> | 2018-02-14 12:55:38 -0500 |
| commit | 97aae076bd3964aa4e9c697e734e2ff71b10f3c5 (patch) | |
| tree | aa87f36547c3dc819f7b73d08b9b798a3eb14f2f | |
| parent | f31c574f7aaf17a26b19e69a647b0849234feaaa (diff) | |
add some more logging
| -rw-r--r-- | src/commands.rs | 4 | ||||
| -rw-r--r-- | src/main.rs | 7 |
2 files changed, 8 insertions, 3 deletions
diff --git a/src/commands.rs b/src/commands.rs index cb39a74..711cf25 100644 --- a/src/commands.rs +++ b/src/commands.rs @@ -91,6 +91,7 @@ impl PlayQueue { let mut manager = voice_manager.lock(); manager.leave(*TARGET_GUILD_ID); + debug!("disconnected due to inactivity"); } sleep(); @@ -108,6 +109,8 @@ impl PlayQueue { } }; + trace!("got ytdl item for {}", item.url); + let mut manager = voice_manager.lock(); let handler = manager.join(*TARGET_GUILD_ID, must_env_lookup::<u64>("VOICE_CHANNEL")); @@ -118,6 +121,7 @@ impl PlayQueue { init_args: item, audio, }); + debug!("playing new song"); }, None => { error!("couldn't join channel"); diff --git a/src/main.rs b/src/main.rs index 8c83fab..d71ee0a 100644 --- a/src/main.rs +++ b/src/main.rs @@ -74,9 +74,10 @@ fn run() -> Result<()> { .case_insensitivity(true) ) .before(|_ctx, message, cmd| { - debug!("got command {} from user '{}' ({})", cmd, message.author.name, message.author.id); - - message.guild_id().map_or(false, |x| x.0 == *TARGET_GUILD) + let result = message.guild_id().map_or(false, |x| x.0 == *TARGET_GUILD); + debug!("got command {} from user '{}' ({}). accept: {}", cmd, message.author.name, message.author.id, result); + + result }) .after(|_ctx, _msg, _cmd, err| { match err { |
