Fix: can't show own profile
This commit is contained in:
1 parent
3144ea24b9
commit
c93262fc54
1 file changed
+2
-2
@@ -106,7 +106,7 @@ namespace ServerLib
|
|||||||
public SProfileData GetProfile(int profileId)
|
public SProfileData GetProfile(int profileId)
|
||||||
{
|
{
|
||||||
Guid sessionKey = _GetSession();
|
Guid sessionKey = _GetSession();
|
||||||
if (_CheckRight(EUserRights.ViewOtherProfiles) || CSessionControl.GetUserIdFromSession(sessionKey) == profileId)
|
if (CSessionControl.GetUserIdFromSession(sessionKey) == profileId || _CheckRight(EUserRights.ViewOtherProfiles))
|
||||||
{
|
{
|
||||||
if (CServer.GetProfileData == null)
|
if (CServer.GetProfileData == null)
|
||||||
{
|
{
|
||||||
@@ -469,7 +469,7 @@ namespace ServerLib
|
|||||||
}
|
}
|
||||||
int userId = CSessionControl.GetUserIdFromSession(sessionKey);
|
int userId = CSessionControl.GetUserIdFromSession(sessionKey);
|
||||||
CPlayerCommunication.AddMessagesFromPlayer(recivedData, userId);
|
CPlayerCommunication.AddMessagesFromPlayer(recivedData, userId);
|
||||||
|
|
||||||
return CPlayerCommunication.GetAllMessagesForPlayer(userId);
|
return CPlayerCommunication.GetAllMessagesForPlayer(userId);
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|||||||
Reference in new issue
Block a user