* Applying Ahzz's profile patch. Thanks Ahzz!

* Fixed a few bugs in the patch that are sim crashers.
* There's still a bug in mySQL mode/ grid mode where the main userprofile text doesn't save.
This commit is contained in:
Teravus Ovares
2008-03-03 08:30:36 +00:00
parent c953e51c11
commit fe49c96ee0
15 changed files with 350 additions and 36 deletions

View File

@@ -139,11 +139,10 @@ namespace OpenSim.Framework.UserManagement
}
/// <summary>
/// Set's user profile from object
/// Set's user profile from data object
/// </summary>
/// <param name="fname">First name</param>
/// <param name="lname">Last name</param>
/// <returns>A user profile</returns>
/// <param name="data"></param>
/// <returns></returns>
public bool setUserProfile(UserProfileData data)
{
foreach (KeyValuePair<string, IUserData> plugin in _plugins)
@@ -158,7 +157,6 @@ namespace OpenSim.Framework.UserManagement
m_log.Info("[USERSTORAGE]: Unable to set user via " + plugin.Key + "(" + e.ToString() + ")");
}
}
return false;
}
@@ -534,6 +532,29 @@ namespace OpenSim.Framework.UserManagement
return user.UUID;
}
public bool UpdateUserProfileProperties(UserProfileData UserProfile)
{
if (null == GetUserProfile(UserProfile.UUID))
{
m_log.Info("[USERSTORAGE]: Failed to find User by UUID " + UserProfile.UUID.ToString());
return false;
}
foreach (KeyValuePair<string, IUserData> plugin in _plugins)
{
try
{
plugin.Value.UpdateUserProfile(UserProfile);
}
catch (Exception e)
{
m_log.Info("[USERSTORAGE]: Unable to update user " + UserProfile.UUID.ToString()
+ " via " + plugin.Key + "(" + e.ToString() + ")");
return false;
}
}
return true;
}
public abstract UserProfileData SetupMasterUser(string firstName, string lastName);
public abstract UserProfileData SetupMasterUser(string firstName, string lastName, string password);
public abstract UserProfileData SetupMasterUser(LLUUID uuid);