Delete change_nick() func, use join_gc() instead. Fixes #2903.
This commit is contained in:
		
							parent
							
								
									039fbb7953
								
							
						
					
					
						commit
						05f306115e
					
				
					 2 changed files with 3 additions and 10 deletions
				
			
		|  | @ -1170,13 +1170,6 @@ class Connection(ConnectionHandlers): | ||||||
| 			to = room_jid) | 			to = room_jid) | ||||||
| 		self.connection.send(iq) | 		self.connection.send(iq) | ||||||
| 
 | 
 | ||||||
| 	def change_gc_nick(self, room_jid, nick): |  | ||||||
| 		if not self.connection: |  | ||||||
| 			return |  | ||||||
| 		p = common.xmpp.Presence(to = '%s/%s' % (room_jid, nick)) |  | ||||||
| 		p = self.add_sha(p) |  | ||||||
| 		self.connection.send(p) |  | ||||||
| 
 |  | ||||||
| 	def send_gc_status(self, nick, jid, show, status): | 	def send_gc_status(self, nick, jid, show, status): | ||||||
| 		if not self.connection: | 		if not self.connection: | ||||||
| 			return | 			return | ||||||
|  |  | ||||||
|  | @ -1048,7 +1048,7 @@ class GroupchatControl(ChatControlBase): | ||||||
| 			if len(message_array) and message_array[0] != self.nick: | 			if len(message_array) and message_array[0] != self.nick: | ||||||
| 				nick = message_array[0] | 				nick = message_array[0] | ||||||
| 				nick = helpers.parse_resource(nick) | 				nick = helpers.parse_resource(nick) | ||||||
| 				gajim.connections[self.account].change_gc_nick(self.room_jid, nick) | 				gajim.connections[self.account].join_gc(nick, self.room_jid, None) | ||||||
| 				self.clear(self.msg_textview) | 				self.clear(self.msg_textview) | ||||||
| 			else: | 			else: | ||||||
| 				self.get_command_help(command) | 				self.get_command_help(command) | ||||||
|  | @ -1329,7 +1329,7 @@ class GroupchatControl(ChatControlBase): | ||||||
| 		def on_ok(widget): | 		def on_ok(widget): | ||||||
| 			nick = instance.input_entry.get_text().decode('utf-8') | 			nick = instance.input_entry.get_text().decode('utf-8') | ||||||
| 			nick = helpers.parse_resource(nick) | 			nick = helpers.parse_resource(nick) | ||||||
| 			gajim.connections[self.account].change_gc_nick(self.room_jid, nick) | 			gajim.connections[self.account].join_gc(nick, self.room_jid, None) | ||||||
| 			self.nick = nick | 			self.nick = nick | ||||||
| 		instance = dialogs.InputDialog(title, prompt, proposed_nick, | 		instance = dialogs.InputDialog(title, prompt, proposed_nick, | ||||||
| 			is_modal = False, ok_handler = on_ok) | 			is_modal = False, ok_handler = on_ok) | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue