Some useful comments
This commit is contained in:
@@ -848,6 +848,14 @@ namespace LibreMetaverse
|
||||
foreach (KeyValuePair<string, OSD> o in linksOsd)
|
||||
{
|
||||
var link = (OSDMap)o.Value;
|
||||
/*
|
||||
* Objects that have been attached in-world prior to being stored on the
|
||||
* asset server are stored with the InventoryType of 0 (Texture)
|
||||
* instead of 17 (Attachment)
|
||||
*
|
||||
* This corrects that behavior by forcing Object Asset types that have an
|
||||
* invalid InventoryType with the proper InventoryType of Attachment.
|
||||
*/
|
||||
InventoryType type = (InventoryType)link["inv_type"].AsInteger();
|
||||
if (type == InventoryType.Texture && (AssetType)link["type"].AsInteger() == AssetType.Object)
|
||||
{
|
||||
|
||||
@@ -333,7 +333,14 @@ namespace OpenMetaverse
|
||||
public static InventoryItem FromOSD(OSD data)
|
||||
{
|
||||
OSDMap descItem = (OSDMap)data;
|
||||
|
||||
/*
|
||||
* Objects that have been attached in-world prior to being stored on the
|
||||
* asset server are stored with the InventoryType of 0 (Texture)
|
||||
* instead of 17 (Attachment)
|
||||
*
|
||||
* This corrects that behavior by forcing Object Asset types that have an
|
||||
* invalid InventoryType with the proper InventoryType of Attachment.
|
||||
*/
|
||||
InventoryType type = (InventoryType)descItem["inv_type"].AsInteger();
|
||||
if (type == InventoryType.Texture && (AssetType)descItem["type"].AsInteger() == AssetType.Object)
|
||||
{
|
||||
|
||||
@@ -3437,7 +3437,7 @@ namespace OpenMetaverse
|
||||
if (uint.TryParse(value, out timestamp))
|
||||
creationDate = Utils.UnixTimeToDateTime(timestamp);
|
||||
else
|
||||
Logger.Log("Failed to parse creation_date " + value, Helpers.LogLevel.Warning);
|
||||
Logger.Log($"Failed to parse creation_date: {value}", Helpers.LogLevel.Warning);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user