Webserver:
-fix: Creating a player fails -fix: Some error messages appear, even all is fine -mod: removed the password set function (setting password is now a profile change)
This commit is contained in:
1 parent
a69dd4344d
commit
38c506cd18
4 files changed
+48
-47
No files matched your search
@@ -81,7 +81,8 @@ namespace ServerLib
|
||||
|
||||
if (profile.ProfileId != -1) //-1 is the id for a new profile
|
||||
{
|
||||
if (!(_CheckRight(EUserRights.EditAllProfiles) || CSessionControl.GetUserIdFromSession(sessionKey) == profile.ProfileId))
|
||||
if (!(_CheckRight(EUserRights.EditAllProfiles)
|
||||
|| CSessionControl.GetUserIdFromSession(sessionKey) == profile.ProfileId))
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -97,17 +98,6 @@ namespace ServerLib
|
||||
return;
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(profile.Password))
|
||||
{
|
||||
int profileId = profile.ProfileId;
|
||||
if (profileId == -1)
|
||||
{
|
||||
profileId = CServer.GetUserIdFromUsername(profile.PlayerName);
|
||||
}
|
||||
|
||||
CServer.SetPassword(profileId, profile.Password);
|
||||
}
|
||||
|
||||
CServer.SendProfileData(profile);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user