Prevent a null ref if a notecard is not found

0.6.5-rc1
Melanie Thielker 2009-04-20 13:56:16 +00:00
parent 489758f68a
commit 6a8fe8a84e
1 changed files with 6 additions and 0 deletions

View File

@ -9209,6 +9209,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
WithNotecard(assetID, delegate (UUID id, AssetBase a) WithNotecard(assetID, delegate (UUID id, AssetBase a)
{ {
if (a == null)
return;
if (a.Type != 7) if (a.Type != 7)
return; return;
@ -9283,6 +9286,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
WithNotecard(assetID, delegate (UUID id, AssetBase a) WithNotecard(assetID, delegate (UUID id, AssetBase a)
{ {
if (a == null)
return;
if (a.Type != 7) if (a.Type != 7)
return; return;