aboutsummaryrefslogtreecommitdiffstats
path: root/src/bot
diff options
context:
space:
mode:
authorJokler <jokler@protonmail.com>2020-01-28 18:42:33 +0100
committerJokler <jokler@protonmail.com>2020-01-29 20:39:27 +0100
commit33f9989df92deebf589b1d0384a6fe485a5492d9 (patch)
treeda2814260b808809627aebf9029586767f44e129 /src/bot
parent1e00d60298697e7443f66ad7a63bc0492bb8072f (diff)
downloadpokebot-33f9989df92deebf589b1d0384a6fe485a5492d9.tar.gz
pokebot-33f9989df92deebf589b1d0384a6fe485a5492d9.zip
Make local mode spawn a music bot directly
Diffstat (limited to 'src/bot')
-rw-r--r--src/bot/music.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/bot/music.rs b/src/bot/music.rs
index 821087c..dee1514 100644
--- a/src/bot/music.rs
+++ b/src/bot/music.rs
@@ -368,6 +368,7 @@ impl MusicBot {
}
fn spawn_stdin_reader(tx: Arc<Mutex<UnboundedSender<MusicBotMessage>>>) {
+ debug!("Spawning stdin reader thread");
thread::spawn(move || {
let stdin = ::std::io::stdin();
let lock = stdin.lock();
@@ -375,7 +376,7 @@ fn spawn_stdin_reader(tx: Arc<Mutex<UnboundedSender<MusicBotMessage>>>) {
let line = line.unwrap();
let message = MusicBotMessage::TextMessage(Message {
- target: MessageTarget::Server,
+ target: MessageTarget::Channel,
invoker: Invoker {
name: String::from("stdin"),
id: ClientId(0),