From ba132f3a0bbbc2f749bec9c563e169d22c76f74b Mon Sep 17 00:00:00 2001
From: Justin Clarke Casey
Date: Thu, 10 Apr 2008 15:28:52 +0000
Subject: * Minor: get CreateNewUserInventory() to return true on success
---
OpenSim/Framework/Communications/IInventoryServices.cs | 5 +++--
OpenSim/Framework/Communications/InventoryServiceBase.cs | 6 +++++-
OpenSim/Region/Communications/OGS1/OGS1InventoryService.cs | 3 ++-
3 files changed, 10 insertions(+), 4 deletions(-)
(limited to 'OpenSim')
diff --git a/OpenSim/Framework/Communications/IInventoryServices.cs b/OpenSim/Framework/Communications/IInventoryServices.cs
index eaa2350..966ab75 100644
--- a/OpenSim/Framework/Communications/IInventoryServices.cs
+++ b/OpenSim/Framework/Communications/IInventoryServices.cs
@@ -66,10 +66,11 @@ namespace OpenSim.Framework.Communications
void DeleteInventoryItem(LLUUID userID, InventoryItemBase item);
///
- /// Create a new inventory for the given user
+ /// Create a new inventory for the given user.
///
///
- void CreateNewUserInventory(LLUUID user);
+ /// true if the inventory was successfully created, false otherwise
+ bool CreateNewUserInventory(LLUUID user);
bool HasInventoryForUser(LLUUID userID);
diff --git a/OpenSim/Framework/Communications/InventoryServiceBase.cs b/OpenSim/Framework/Communications/InventoryServiceBase.cs
index 0d19932..f9a47b1 100644
--- a/OpenSim/Framework/Communications/InventoryServiceBase.cs
+++ b/OpenSim/Framework/Communications/InventoryServiceBase.cs
@@ -135,7 +135,7 @@ namespace OpenSim.Framework.Communications
}
// See IInventoryServices
- public void CreateNewUserInventory(LLUUID user)
+ public bool CreateNewUserInventory(LLUUID user)
{
InventoryFolderBase existingRootFolder = RequestRootFolder(user);
@@ -151,7 +151,11 @@ namespace OpenSim.Framework.Communications
UsersInventory inven = new UsersInventory();
inven.CreateNewInventorySet(user);
AddNewInventorySet(inven);
+
+ return true;
}
+
+ return false;
}
public abstract void RequestInventoryForUser(LLUUID userID, InventoryFolderInfo folderCallBack,
diff --git a/OpenSim/Region/Communications/OGS1/OGS1InventoryService.cs b/OpenSim/Region/Communications/OGS1/OGS1InventoryService.cs
index 3a13f71..b18c5bf 100644
--- a/OpenSim/Region/Communications/OGS1/OGS1InventoryService.cs
+++ b/OpenSim/Region/Communications/OGS1/OGS1InventoryService.cs
@@ -208,8 +208,9 @@ namespace OpenSim.Region.Communications.OGS1
return null;
}
- public void CreateNewUserInventory(LLUUID user)
+ public bool CreateNewUserInventory(LLUUID user)
{
+ return false;
}
// See IInventoryServices
--
cgit v1.1