Added a null reference check to the insert before function
This commit is contained in:
parent
763223fdd0
commit
003ce41d6b
@ -288,7 +288,7 @@ namespace VEPROMS.CSLA.Library
|
||||
public ItemInfo InsertSiblingBefore(string text, string number,int? type)
|
||||
{
|
||||
ItemInfo tmp = null;
|
||||
if (!IsSection && (FormatStepData.UseSmartTemplate || MyHLS.FormatStepData.UseSmartTemplate || FormatStepData.UseOldTemplate))
|
||||
if (!IsSection && (FormatStepData.UseSmartTemplate || (MyHLS!=null && MyHLS.FormatStepData.UseSmartTemplate) || FormatStepData.UseOldTemplate))
|
||||
tmp = InsertSmartTemplateSteps(text, number, tmp, EAddpingPart.Before, (int)MyContent.Type);
|
||||
if (tmp == null)
|
||||
tmp = NewItemInfoFetch(ItemID, EAddpingPart.Before, number, text, type, null, null, null, DateTime.Now, Volian.Base.Library.VlnSettings.UserID);
|
||||
|
Loading…
x
Reference in New Issue
Block a user