Fixes null propogation
This commit is contained in:
parent
22ab83ea9e
commit
3c9842ee5a
218 changed files with 799 additions and 1458 deletions
|
|
@ -83,8 +83,7 @@ namespace Server.Items
|
|||
|
||||
public override void OnDelete()
|
||||
{
|
||||
if ( m_Commodity != null )
|
||||
m_Commodity.Delete();
|
||||
m_Commodity?.Delete();
|
||||
|
||||
base.OnDelete();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -139,10 +139,7 @@ namespace Server.Items
|
|||
{
|
||||
BaseHouse house = BaseHouse.FindHouseAt( this );
|
||||
|
||||
if ( house != null )
|
||||
{
|
||||
house.VendorRentalContracts.Remove( this );
|
||||
}
|
||||
house?.VendorRentalContracts.Remove( this );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue