Core/Errors: Stop using System.Diagnostics.Contracts, Its just closing the server without error or warning. We now log the error and then throw a exception

This commit is contained in:
hondacrx
2018-06-15 12:34:56 -04:00
parent 1289bc3ed1
commit 7aa494d5dd
86 changed files with 520 additions and 558 deletions
+2 -3
View File
@@ -16,7 +16,6 @@
*/
using System.Collections.Generic;
using System.Diagnostics.Contracts;
using System.Linq;
namespace Framework.Dynamic
@@ -112,13 +111,13 @@ namespace Framework.Dynamic
public void ScheduleAbort()
{
Contract.Assert(IsRunning(), "Tried to scheduled the abortion of an event twice!");
Cypher.Assert(IsRunning(), "Tried to scheduled the abortion of an event twice!");
m_abortState = AbortState.Scheduled;
}
public void SetAborted()
{
Contract.Assert(!IsAborted(), "Tried to abort an already aborted event!");
Cypher.Assert(!IsAborted(), "Tried to abort an already aborted event!");
m_abortState = AbortState.Aborted;
}