Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can read messages but can't seem to send? #103

Closed
sosodev opened this issue Aug 5, 2017 · 1 comment
Closed

Can read messages but can't seem to send? #103

sosodev opened this issue Aug 5, 2017 · 1 comment

Comments

@sosodev
Copy link

sosodev commented Aug 5, 2017

I've been trying to use this library with Twitch's IRC, and everything was going fine until I started trying to send messages.

My code is pretty much the same as the one in the client.go file, but changed to just take the input and send it as a privmsg to the channel.

	go func () {
		message := <- in
		fmt.Println(message)

		if message == "quit"{
			reallyquit = true
			c.Close()
		}

		c.Privmsg(channel, message)
	}()

channel is equal to "#silentserenity", and I've also tried it with just "#"

I can read all incoming messages, and when I input something the input is received and printed correctly, but the privmsg just doesn't seem to work.

Any help would be greatly appreciated, as I just can't seem to figure it out.

@sosodev
Copy link
Author

sosodev commented Aug 7, 2017

I've found the error in my ways... I forgot trim the channel name after the user entered it...

@sosodev sosodev closed this as completed Aug 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant