From 682ffef10169f92a28b42987e6ba47c70de41b8a Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Sat, 16 Aug 2008 05:41:40 +0000 Subject: [PATCH] Reshuffle to eliminate prim owner lookups unless gridgods are enabled --- .../Modules/World/Permissions/PermissionsModule.cs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs index 10f4897eb6..b3da36c22e 100644 --- a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs @@ -246,11 +246,14 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions if (m_scene.RegionInfo.EstateSettings.EstateOwner == user) return true; } - CachedUserInfo profile = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(user); - if(profile != null && profile.UserProfile != null) + if(m_allowGridGods) { - if(profile.UserProfile.GodLevel >= 200 && m_allowGridGods) - return true; + CachedUserInfo profile = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(user); + if(profile != null && profile.UserProfile != null) + { + if(profile.UserProfile.GodLevel >= 200) + return true; + } } return false;