diff options
author | Jesse Plamondon-Willard <github@jplamondonw.com> | 2018-02-15 23:58:27 -0500 |
---|---|---|
committer | Jesse Plamondon-Willard <github@jplamondonw.com> | 2018-02-15 23:58:27 -0500 |
commit | cf383870837748e83b99bf63d36d7a8709743715 (patch) | |
tree | c861da18660f24322b8a879d8096bba5557972f8 /src/SMAPI/Program.cs | |
parent | 032997650010a9b6cd3378cb1a2b8273fb3f56ff (diff) | |
download | SMAPI-cf383870837748e83b99bf63d36d7a8709743715.tar.gz SMAPI-cf383870837748e83b99bf63d36d7a8709743715.tar.bz2 SMAPI-cf383870837748e83b99bf63d36d7a8709743715.zip |
log mod errors and warnings as the mod (#438)
Diffstat (limited to 'src/SMAPI/Program.cs')
-rw-r--r-- | src/SMAPI/Program.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/SMAPI/Program.cs b/src/SMAPI/Program.cs index 7eda9c66..c7da581d 100644 --- a/src/SMAPI/Program.cs +++ b/src/SMAPI/Program.cs @@ -255,7 +255,7 @@ namespace StardewModdingAPI } catch (Exception ex) { - this.Monitor.Log($"The {mod.DisplayName} mod failed during disposal: {ex.GetLogSummary()}.", LogLevel.Warn); + mod.LogAsMod($"Mod failed during disposal: {ex.GetLogSummary()}.", LogLevel.Warn); } } @@ -793,7 +793,7 @@ namespace StardewModdingAPI } catch (Exception ex) { - this.Monitor.Log($"{metadata.DisplayName} failed on entry and might not work correctly. Technical details:\n{ex.GetLogSummary()}", LogLevel.Error); + metadata.LogAsMod($"Mod crashed on entry and might not work correctly. Technical details:\n{ex.GetLogSummary()}", LogLevel.Error); } // get mod API @@ -900,7 +900,7 @@ namespace StardewModdingAPI } catch (Exception ex) { - this.Monitor.Log($"Couldn't read {metadata.DisplayName}'s i18n/{locale}.json file: {ex.GetLogSummary()}"); + metadata.LogAsMod($"Mod's i18n/{locale}.json file couldn't be parsed: {ex.GetLogSummary()}"); } } } |