DEBUG preprocessor checks for ILog
This commit is contained in:
parent
371beb8c52
commit
fc1d188951
6 changed files with 16 additions and 2 deletions
|
|
@ -849,7 +849,7 @@ namespace TShockAPI
|
|||
{
|
||||
if (displayConsole)
|
||||
{
|
||||
TShock.Log.ConsoleInfo("Player {0} has been disabled for {1}.", Name, reason);
|
||||
TShock.Log.ConsoleInfo("Player {0} has been disabled for {1}.", Name, reason);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -858,11 +858,13 @@ namespace TShockAPI
|
|||
LastDisableNotification = DateTime.UtcNow;
|
||||
}
|
||||
}
|
||||
#if DEBUG
|
||||
var trace = new StackTrace();
|
||||
StackFrame frame = null;
|
||||
frame = trace.GetFrame(1);
|
||||
if (frame != null && frame.GetMethod().DeclaringType != null)
|
||||
TShock.Log.Debug(frame.GetMethod().DeclaringType.Name + " called Disable().");
|
||||
#endif
|
||||
}
|
||||
|
||||
public virtual void Whoopie(object time)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue