diff options
Diffstat (limited to 'OpenSim/Region')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index 4bf8729..4aac9a0 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | |||
@@ -1666,17 +1666,25 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
1666 | { | 1666 | { |
1667 | if(newLand.GroupID != uuid) | 1667 | if(newLand.GroupID != uuid) |
1668 | { | 1668 | { |
1669 | IGroupsModule groupsModule = m_ScriptEngine.World.RequestModuleInterface<IGroupsModule>(); | 1669 | if(uuid == UUID.Zero) |
1670 | GroupMembershipData member = null; | ||
1671 | if (groupsModule != null) | ||
1672 | member = groupsModule.GetMembershipData(uuid, newLand.OwnerID); | ||
1673 | if (member == null) | ||
1674 | OSSLError(string.Format("land owner is not member of the new group for parcel")); | ||
1675 | else | ||
1676 | { | 1670 | { |
1677 | changed = true; | 1671 | changed = true; |
1678 | newLand.GroupID = uuid; | 1672 | newLand.GroupID = uuid; |
1679 | } | 1673 | } |
1674 | else | ||
1675 | { | ||
1676 | IGroupsModule groupsModule = m_ScriptEngine.World.RequestModuleInterface<IGroupsModule>(); | ||
1677 | GroupMembershipData member = null; | ||
1678 | if (groupsModule != null) | ||
1679 | member = groupsModule.GetMembershipData(uuid, newLand.OwnerID); | ||
1680 | if (member == null) | ||
1681 | OSSLError(string.Format("land owner is not member of the new group for parcel")); | ||
1682 | else | ||
1683 | { | ||
1684 | changed = true; | ||
1685 | newLand.GroupID = uuid; | ||
1686 | } | ||
1687 | } | ||
1680 | } | 1688 | } |
1681 | } | 1689 | } |
1682 | } | 1690 | } |