Date default should be null

This commit is contained in:
Matt Nadareski
2020-08-24 13:59:59 -07:00
parent 77cdda1c6e
commit 80874d40d7
2 changed files with 5 additions and 2 deletions

View File

@@ -237,11 +237,10 @@ namespace SabreTools.Library.DatItems
/// </summary> /// </summary>
public Rom() public Rom()
{ {
Name = string.Empty; Name = null;
ItemType = ItemType.Rom; ItemType = ItemType.Rom;
DupeType = 0x00; DupeType = 0x00;
ItemStatus = ItemStatus.None; ItemStatus = ItemStatus.None;
Date = string.Empty;
} }
/// <summary> /// <summary>

View File

@@ -17,6 +17,10 @@ namespace SabreTools.Library.Tools
/// <returns>Date as a string, if possible</returns> /// <returns>Date as a string, if possible</returns>
public static string CleanDate(string input) public static string CleanDate(string input)
{ {
// Null in, null out
if (input == null)
return null;
string date = string.Empty; string date = string.Empty;
if (input != null) if (input != null)
{ {