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

When invited to a room the bot should not join if the room is public #298

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

elmobp
Copy link

@elmobp elmobp commented Jul 14, 2017

If you tell hubot not to join public rooms it only applies at start up not when the bot is running, this way the bot will only join a room whilst it is running if the room is not public.

if rooms
for room in rooms
if [email protected]_join_public && room.guest_url != '' && room.jid == jid
@logger.info "Not joining #{room.jid} because it is a public room"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you don't join the room, you won't be able to receive messages from that room. Is that the objective?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeh, if you tell hubot not to join public rooms it only applies at boot. Thought if invited whilst it is running it will then join a public room

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

Successfully merging this pull request may close these issues.

2 participants