From 064a2ea4605c8eda8f9032e5185e3c754f7948f7 Mon Sep 17 00:00:00 2001 From: Dahlia Trimble Date: Mon, 23 Jun 2008 09:31:08 +0000 Subject: changed kickuser console command to use caseless compared substrings for first and last name parameters --- OpenSim/Region/Application/OpenSim.cs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'OpenSim/Region/Application') diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs index 12977a8..714d8eb 100644 --- a/OpenSim/Region/Application/OpenSim.cs +++ b/OpenSim/Region/Application/OpenSim.cs @@ -149,20 +149,17 @@ namespace OpenSim if (cmdparams.Length < 2) return; - string firstName = cmdparams[0]; - string lastName = cmdparams[1]; - IList agents = m_sceneManager.GetCurrentSceneAvatars(); foreach (ScenePresence presence in agents) { RegionInfo regionInfo = m_sceneManager.GetRegionInfo(presence.RegionHandle); - if (presence.Firstname.ToLower().Equals(firstName) && presence.Lastname.ToLower().Equals(lastName)) + if (presence.Firstname.ToLower().Contains(cmdparams[0].ToLower()) && presence.Lastname.ToLower().Contains(cmdparams[1].ToLower())) { m_console.Notice( String.Format( - "Found user: {0,-16}{1,-16}{2,-37} in region: {3,-16}", + "Kicking user: {0,-16}{1,-16}{2,-37} in region: {3,-16}", presence.Firstname, presence.Lastname, presence.UUID, @@ -172,7 +169,6 @@ namespace OpenSim } } m_console.Notice(""); - } /// -- cgit v1.1