1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2024-11-22 20:12:07 +01:00

Synchronize MultiUserchat.changeNickname(Resourcepart)

This commit is contained in:
Florian Schmaus 2015-04-23 21:45:33 +02:00
parent 00a7556bfe
commit 5af4f1a5d1

View file

@ -969,7 +969,7 @@ public class MultiUserChat {
* @throws InterruptedException * @throws InterruptedException
* @throws MucNotJoinedException * @throws MucNotJoinedException
*/ */
public void changeNickname(Resourcepart nickname) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException, MucNotJoinedException { public synchronized void changeNickname(Resourcepart nickname) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException, MucNotJoinedException {
StringUtils.requireNotNullOrEmpty(nickname, "Nickname must not be null or blank."); StringUtils.requireNotNullOrEmpty(nickname, "Nickname must not be null or blank.");
// Check that we already have joined the room before attempting to change the // Check that we already have joined the room before attempting to change the
// nickname. // nickname.