Switched to using the other Util function with a default value.
parent
64b8ce73da
commit
bb44758179
|
@ -65,7 +65,8 @@ namespace OpenSim.Groups
|
|||
|
||||
m_log.DebugFormat("[Groups.RobustHGConnector]: Starting with config name {0}", m_ConfigName);
|
||||
|
||||
string homeURI = Util.GetConfigVarFromSections<string>(config, "HomeURI", new string[] { "Startup", "Hypergrid", m_ConfigName} ); //cnf.GetString("HomeURI", string.Empty);
|
||||
string homeURI = Util.GetConfigVarFromSections<string>(config, "HomeURI",
|
||||
new string[] { "Startup", "Hypergrid", m_ConfigName}, string.Empty);
|
||||
if (homeURI == string.Empty)
|
||||
throw new Exception(String.Format("[Groups.RobustHGConnector]: please provide the HomeURI [Startup] or in section {0}", m_ConfigName));
|
||||
|
||||
|
|
|
@ -65,7 +65,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Lure
|
|||
{
|
||||
m_Enabled = true;
|
||||
|
||||
m_ThisGridURL = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", new string[] { "Startup", "Hypergrid", "Messaging" });
|
||||
m_ThisGridURL = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid", "Messaging" }, String.Empty);
|
||||
// Legacy. Remove soon!
|
||||
m_ThisGridURL = config.Configs["Messaging"].GetString("Gatekeeper", m_ThisGridURL);
|
||||
m_log.DebugFormat("[LURE MODULE]: {0} enabled", Name);
|
||||
|
|
|
@ -88,8 +88,10 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
|||
IConfig thisModuleConfig = source.Configs["HGInventoryAccessModule"];
|
||||
if (thisModuleConfig != null)
|
||||
{
|
||||
m_HomeURI = Util.GetConfigVarFromSections<string>(source, "HomeURI", new string[] { "Startup", "Hypergrid", "HGInventoryAccessModule" });
|
||||
m_ThisGatekeeper = Util.GetConfigVarFromSections<string>(source, "GatekeeperURI", new string[] { "Startup", "Hypergrid", "HGInventoryAccessModule" });
|
||||
m_HomeURI = Util.GetConfigVarFromSections<string>(source, "HomeURI",
|
||||
new string[] { "Startup", "Hypergrid", "HGInventoryAccessModule" }, String.Empty);
|
||||
m_ThisGatekeeper = Util.GetConfigVarFromSections<string>(source, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid", "HGInventoryAccessModule" }, String.Empty);
|
||||
// Legacy. Renove soon!
|
||||
m_ThisGatekeeper = thisModuleConfig.GetString("Gatekeeper", m_ThisGatekeeper);
|
||||
|
||||
|
|
|
@ -113,7 +113,8 @@ namespace OpenSim.Region.DataSnapshot
|
|||
try
|
||||
{
|
||||
m_enabled = config.Configs["DataSnapshot"].GetBoolean("index_sims", m_enabled);
|
||||
string gatekeeper = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", new string[] { "Startup", "Hypergrid", "GridService" });
|
||||
string gatekeeper = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid", "GridService" }, String.Empty);
|
||||
// Legacy. Remove soon!
|
||||
if (string.IsNullOrEmpty(gatekeeper))
|
||||
{
|
||||
|
|
|
@ -2138,7 +2138,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
|||
m_host.AddScriptLPS(1);
|
||||
|
||||
IConfigSource config = m_ScriptEngine.ConfigSource;
|
||||
string HomeURI = Util.GetConfigVarFromSections<string>(config, "HomeURI", new string[] { "Startup", "Hypergrid" });
|
||||
string HomeURI = Util.GetConfigVarFromSections<string>(config, "HomeURI",
|
||||
new string[] { "Startup", "Hypergrid" }, String.Empty);
|
||||
|
||||
if (!string.IsNullOrEmpty(HomeURI))
|
||||
return HomeURI;
|
||||
|
@ -2159,7 +2160,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
|||
m_host.AddScriptLPS(1);
|
||||
|
||||
IConfigSource config = m_ScriptEngine.ConfigSource;
|
||||
string gatekeeperURI = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", new string[] { "Startup", "Hypergrid" });
|
||||
string gatekeeperURI = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid" }, String.Empty);
|
||||
|
||||
if (!string.IsNullOrEmpty(gatekeeperURI))
|
||||
return gatekeeperURI;
|
||||
|
|
|
@ -177,7 +177,8 @@ namespace OpenSim.Server.Handlers.Grid
|
|||
map[k] = OSD.FromString(_info[k].ToString());
|
||||
}
|
||||
|
||||
string HomeURI = Util.GetConfigVarFromSections<string>(m_Config, "HomeURI", new string[] { "Startup", "Hypergrid" });
|
||||
string HomeURI = Util.GetConfigVarFromSections<string>(m_Config, "HomeURI",
|
||||
new string[] { "Startup", "Hypergrid" }, String.Empty);
|
||||
|
||||
if (!String.IsNullOrEmpty(HomeURI))
|
||||
map["home"] = OSD.FromString(HomeURI);
|
||||
|
|
|
@ -128,7 +128,8 @@ namespace OpenSim.Services.GridService
|
|||
|
||||
m_MapTileDirectory = gridConfig.GetString("MapTileDirectory", "maptiles");
|
||||
|
||||
m_ThisGatekeeper = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", new string[] { "Startup", "Hypergrid", "GridService" });
|
||||
m_ThisGatekeeper = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid", "GridService" }, String.Empty);
|
||||
// Legacy. Remove soon!
|
||||
m_ThisGatekeeper = gridConfig.GetString("Gatekeeper", m_ThisGatekeeper);
|
||||
try
|
||||
|
|
|
@ -96,7 +96,8 @@ namespace OpenSim.Services.HypergridService
|
|||
UUID.TryParse(scope, out m_ScopeID);
|
||||
//m_WelcomeMessage = serverConfig.GetString("WelcomeMessage", "Welcome to OpenSim!");
|
||||
m_AllowTeleportsToAnyRegion = serverConfig.GetBoolean("AllowTeleportsToAnyRegion", true);
|
||||
m_ExternalName = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", new string[] { "Startup", "Hypergrid", "GatekeeperService" });
|
||||
m_ExternalName = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid", "GatekeeperService" }, String.Empty);
|
||||
m_ExternalName = serverConfig.GetString("ExternalName", m_ExternalName);
|
||||
if (m_ExternalName != string.Empty && !m_ExternalName.EndsWith("/"))
|
||||
m_ExternalName = m_ExternalName + "/";
|
||||
|
|
|
@ -81,7 +81,8 @@ namespace OpenSim.Services.HypergridService
|
|||
if (m_UserAccountService == null)
|
||||
throw new Exception(String.Format("Unable to create UserAccountService from {0}", userAccountsDll));
|
||||
|
||||
m_HomeURL = Util.GetConfigVarFromSections<string>(config, "HomeURI", new string[] { "Startup", "Hypergrid", m_ConfigName });
|
||||
m_HomeURL = Util.GetConfigVarFromSections<string>(config, "HomeURI",
|
||||
new string[] { "Startup", "Hypergrid", m_ConfigName }, String.Empty);
|
||||
|
||||
m_Cache = UserAccountCache.CreateUserAccountCache(m_UserAccountService);
|
||||
}
|
||||
|
|
|
@ -96,7 +96,8 @@ namespace OpenSim.Services.HypergridService
|
|||
if (m_AvatarService == null)
|
||||
throw new Exception(String.Format("Unable to create m_AvatarService from {0}", avatarDll));
|
||||
|
||||
m_HomeURL = Util.GetConfigVarFromSections<string>(config, "HomeURI", new string[] { "Startup", "Hypergrid", m_ConfigName });
|
||||
m_HomeURL = Util.GetConfigVarFromSections<string>(config, "HomeURI",
|
||||
new string[] { "Startup", "Hypergrid", m_ConfigName }, String.Empty);
|
||||
|
||||
// m_Cache = UserAccountCache.CreateUserAccountCache(m_UserAccountService);
|
||||
}
|
||||
|
|
|
@ -131,7 +131,8 @@ namespace OpenSim.Services.HypergridService
|
|||
LoadDomainExceptionsFromConfig(serverConfig, "AllowExcept", m_TripsAllowedExceptions);
|
||||
LoadDomainExceptionsFromConfig(serverConfig, "DisallowExcept", m_TripsDisallowedExceptions);
|
||||
|
||||
m_GridName = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", new string[] { "Startup", "Hypergrid", "UserAgentService" });
|
||||
m_GridName = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid", "UserAgentService" }, String.Empty);
|
||||
if (string.IsNullOrEmpty(m_GridName)) // Legacy. Remove soon.
|
||||
{
|
||||
m_GridName = serverConfig.GetString("ExternalName", string.Empty);
|
||||
|
|
|
@ -110,7 +110,8 @@ namespace OpenSim.Services.LLLoginService
|
|||
m_RequireInventory = m_LoginServerConfig.GetBoolean("RequireInventory", true);
|
||||
m_AllowRemoteSetLoginLevel = m_LoginServerConfig.GetBoolean("AllowRemoteSetLoginLevel", false);
|
||||
m_MinLoginLevel = m_LoginServerConfig.GetInt("MinLoginLevel", 0);
|
||||
m_GatekeeperURL = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", new string[] { "Startup", "Hypergrid", "LoginService" });
|
||||
m_GatekeeperURL = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI",
|
||||
new string[] { "Startup", "Hypergrid", "LoginService" }, String.Empty);
|
||||
m_MapTileURL = m_LoginServerConfig.GetString("MapTileURL", string.Empty);
|
||||
m_ProfileURL = m_LoginServerConfig.GetString("ProfileServerURL", string.Empty);
|
||||
m_OpenIDURL = m_LoginServerConfig.GetString("OpenIDServerURL", String.Empty);
|
||||
|
|
Loading…
Reference in New Issue