diff options
author | Jesse Plamondon-Willard <github@jplamondonw.com> | 2017-04-26 14:38:47 -0400 |
---|---|---|
committer | Jesse Plamondon-Willard <github@jplamondonw.com> | 2017-04-26 14:38:47 -0400 |
commit | 89221b8b2d88668238d89af38484784c8bd16116 (patch) | |
tree | 92cd853fc1dbaca1e1b737c62c5c169bf9a95136 /src/StardewModdingAPI/Framework | |
parent | 22806ab900721a61b142937bc58dd33727d377f9 (diff) | |
download | SMAPI-89221b8b2d88668238d89af38484784c8bd16116.tar.gz SMAPI-89221b8b2d88668238d89af38484784c8bd16116.tar.bz2 SMAPI-89221b8b2d88668238d89af38484784c8bd16116.zip |
add editorconfig, minor style fixes
Diffstat (limited to 'src/StardewModdingAPI/Framework')
-rw-r--r-- | src/StardewModdingAPI/Framework/DeprecationManager.cs | 2 | ||||
-rw-r--r-- | src/StardewModdingAPI/Framework/Monitor.cs | 4 |
2 files changed, 2 insertions, 4 deletions
diff --git a/src/StardewModdingAPI/Framework/DeprecationManager.cs b/src/StardewModdingAPI/Framework/DeprecationManager.cs index e44cd369..6b95960b 100644 --- a/src/StardewModdingAPI/Framework/DeprecationManager.cs +++ b/src/StardewModdingAPI/Framework/DeprecationManager.cs @@ -78,7 +78,7 @@ namespace StardewModdingAPI.Framework break; default: - throw new NotImplementedException($"Unknown deprecation level '{severity}'"); + throw new NotSupportedException($"Unknown deprecation level '{severity}'"); } } diff --git a/src/StardewModdingAPI/Framework/Monitor.cs b/src/StardewModdingAPI/Framework/Monitor.cs index 51feff78..dac81f14 100644 --- a/src/StardewModdingAPI/Framework/Monitor.cs +++ b/src/StardewModdingAPI/Framework/Monitor.cs @@ -64,12 +64,10 @@ namespace StardewModdingAPI.Framework // validate if (string.IsNullOrWhiteSpace(source)) throw new ArgumentException("The log source cannot be empty."); - if (logFile == null) - throw new ArgumentNullException(nameof(logFile), "The log file manager cannot be null."); // initialise this.Source = source; - this.LogFile = logFile; + this.LogFile = logFile ?? throw new ArgumentNullException(nameof(logFile), "The log file manager cannot be null."); this.ConsoleManager = consoleManager; this.RequestExit = requestExitDelegate; } |