some cleanup

This commit is contained in:
UbitUmarov
2017-06-13 13:22:01 +01:00
parent 3ba63dde6e
commit 9526a96b4f
4 changed files with 16 additions and 36 deletions

View File

@@ -1604,13 +1604,16 @@ namespace OpenSim.Region.Framework.Scenes
/// <param name="remoteClient"></param>
protected internal void UpdatePrimTexture(uint localID, byte[] texture, IClientAPI remoteClient)
{
SceneObjectGroup group = GetGroupByPrim(localID);
SceneObjectPart part = GetSceneObjectPart(localID);
if(part == null)
return;
if (group != null)
SceneObjectGroup group = part.ParentGroup;
if (group != null && !group.IsDeleted)
{
if (m_parentScene.Permissions.CanEditObject(group, remoteClient))
{
group.UpdateTextureEntry(localID, texture);
part.UpdateTextureEntry(texture);
}
}
}