Skip to content
Snippets Groups Projects
Commit 55ba2388 authored by Yann Leboulanger's avatar Yann Leboulanger
Browse files

don't check if there is a @ when we invite a JID.

parent e4a2ee3c
No related branches found
No related tags found
No related merge requests found
...@@ -1276,19 +1276,13 @@ class GroupchatControl(ChatControlBase): ...@@ -1276,19 +1276,13 @@ class GroupchatControl(ChatControlBase):
if len(message_array): if len(message_array):
message_array = message_array[0].split() message_array = message_array[0].split()
invitee = message_array.pop(0) invitee = message_array.pop(0)
if invitee.find('@') >= 0: reason = ' '.join(message_array)
reason = ' '.join(message_array) gajim.connections[self.account].send_invite(self.room_jid, invitee, reason)
gajim.connections[self.account].send_invite(self.room_jid, s = _('Invited %(contact_jid)s to %(room_jid)s.') % {
invitee, reason) 'contact_jid': invitee,
s = _('Invited %(contact_jid)s to %(room_jid)s.') % { 'room_jid': self.room_jid}
'contact_jid': invitee, self.print_conversation(s, 'info')
'room_jid': self.room_jid} self.clear(self.msg_textview)
self.print_conversation(s, 'info')
self.clear(self.msg_textview)
else:
#%s is something the user wrote but it is not a jid so we inform
s = _('%s does not appear to be a valid JID') % invitee
self.print_conversation(s, 'info')
else: else:
self.get_command_help(command) self.get_command_help(command)
return True return True
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment