From 7025a8040e06250d73c295aa641969d7189474d8 Mon Sep 17 00:00:00 2001 From: Dr Scofield Date: Fri, 25 Jul 2008 09:56:35 +0000 Subject: From: awebb Further improvements to the REST handlers. --- .../ApplicationPlugins/Rest/Inventory/RestAssetServices.cs | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'OpenSim/ApplicationPlugins/Rest/Inventory/RestAssetServices.cs') diff --git a/OpenSim/ApplicationPlugins/Rest/Inventory/RestAssetServices.cs b/OpenSim/ApplicationPlugins/Rest/Inventory/RestAssetServices.cs index 0fc937f..70957f5 100644 --- a/OpenSim/ApplicationPlugins/Rest/Inventory/RestAssetServices.cs +++ b/OpenSim/ApplicationPlugins/Rest/Inventory/RestAssetServices.cs @@ -44,35 +44,31 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory public class RestAssetServices : IRest { - private string key = "assets"; private bool enabled = false; private string qPrefix = "assets"; // A simple constructor is used to handle any once-only // initialization of working classes. - public RestAssetServices(RestHandler p_rest) + public RestAssetServices() { Rest.Log.InfoFormat("{0} Asset services initializing", MsgId); Rest.Log.InfoFormat("{0} Using REST Implementation Version {1}", MsgId, Rest.Version); - // Integrate domain + // If the handler specifies a relative path for its domain + // then we must add the standard absolute prefix, e.g. /admin if (!qPrefix.StartsWith(Rest.UrlPathSeparator)) { qPrefix = Rest.Prefix + Rest.UrlPathSeparator + qPrefix; } - // Authentication domain - - Rest.Domains.Add(key,Rest.Config.GetString("asset-domain",qPrefix)); - - // Register interface + // Register interface using the fully-qualified prefix Rest.Plugin.AddPathHandler(DoAsset, qPrefix, Allocate); - // Activate + // Activate if all went OK enabled = true; -- cgit v1.1