Replaced all DateTime.MaxValue with Constants.DateTimeHigh

This commit is contained in:
Rick Falkvinge
2017-01-16 01:27:33 +01:00
parent 85b61618ba
commit f109c1daa1
6 changed files with 14 additions and 8 deletions
+3 -2
View File
@@ -5,6 +5,7 @@ using System.Data.Common;
using MySql.Data.Types;
using Swarmops.Basic.Types;
using Swarmops.Basic.Types.Swarm;
using Swarmops.Common;
using Swarmops.Common.Enums;
using Swarmops.Common.Interfaces;
@@ -454,7 +455,7 @@ namespace Swarmops.Database
int personId = reader.GetInt32 (1);
int organizationId = reader.GetInt32 (2);
bool active = reader.GetBoolean (3);
DateTime expires = DateTime.MaxValue;
DateTime expires = Constants.DateTimeHigh;
try
{
expires = reader.GetDateTime(4);
@@ -472,7 +473,7 @@ namespace Swarmops.Database
}
catch (MySqlConversionException)
{
// as above, ignore exception and go with DateTime.MaxValue
// as above, ignore exception and go with Constants.DateTimeHigh
}
// bool terminatedAsInvalid = reader.GetBoolean(7); Ignore this field for now