mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2025-12-23 07:28:24 -08:00
fixed #84: game creator couldn't re-join his game if the only buddies flag was set
This commit is contained in:
@@ -359,7 +359,7 @@ Response::ResponseCode Server_Game::checkJoin(ServerInfo_User *user, const QStri
|
|||||||
return Response::RespWrongPassword;
|
return Response::RespWrongPassword;
|
||||||
if (!(user->user_level() & ServerInfo_User::IsRegistered) && onlyRegistered)
|
if (!(user->user_level() & ServerInfo_User::IsRegistered) && onlyRegistered)
|
||||||
return Response::RespUserLevelTooLow;
|
return Response::RespUserLevelTooLow;
|
||||||
if (onlyBuddies)
|
if (onlyBuddies && (user->name() != creatorInfo->name()))
|
||||||
if (!databaseInterface->isInBuddyList(QString::fromStdString(creatorInfo->name()), QString::fromStdString(user->name())))
|
if (!databaseInterface->isInBuddyList(QString::fromStdString(creatorInfo->name()), QString::fromStdString(user->name())))
|
||||||
return Response::RespOnlyBuddies;
|
return Response::RespOnlyBuddies;
|
||||||
if (databaseInterface->isInIgnoreList(QString::fromStdString(creatorInfo->name()), QString::fromStdString(user->name())))
|
if (databaseInterface->isInIgnoreList(QString::fromStdString(creatorInfo->name()), QString::fromStdString(user->name())))
|
||||||
|
|||||||
Reference in New Issue
Block a user