aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs2
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs10
2 files changed, 12 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs
index bd4638a..19a41ec 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs
@@ -208,6 +208,8 @@ namespace OpenSim.Region.CoreModules.ServiceConnectors.Asset
208 public string Store(AssetBase asset) 208 public string Store(AssetBase asset)
209 { 209 {
210 m_Cache.Cache(asset); 210 m_Cache.Cache(asset);
211 if (asset.Temporary || asset.Local)
212 return asset.ID;
211 return m_AssetService.Store(asset); 213 return m_AssetService.Store(asset);
212 } 214 }
213 215
diff --git a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs
index c409d15..4e8b5d6 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs
@@ -230,6 +230,14 @@ namespace OpenSim.Region.CoreModules.ServiceConnectors.Asset
230 230
231 public string Store(AssetBase asset) 231 public string Store(AssetBase asset)
232 { 232 {
233 if (asset.Temporary || asset.Local)
234 {
235 if (m_Cache != null)
236 m_Cache.Cache(asset);
237
238 return asset.ID;
239 }
240
233 string uri = m_ServerURI + "/assets/"; 241 string uri = m_ServerURI + "/assets/";
234 242
235 string newID = SynchronousRestObjectRequester. 243 string newID = SynchronousRestObjectRequester.
@@ -237,6 +245,8 @@ namespace OpenSim.Region.CoreModules.ServiceConnectors.Asset
237 245
238 if (newID != String.Empty) 246 if (newID != String.Empty)
239 { 247 {
248 asset.ID = newID;
249
240 if (m_Cache != null) 250 if (m_Cache != null)
241 m_Cache.Cache(asset); 251 m_Cache.Cache(asset);
242 } 252 }