summaryrefslogtreecommitdiff
path: root/src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2020-02-02 15:01:03 -0500
committerJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2020-02-02 15:01:03 -0500
commit4991b4d6afea97dc6c9aa5174d438cac72e7d116 (patch)
treee7bdd09c8278522653457f9cda2370215d8edee7 /src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs
parent0a2b15d3c36a0a5db4d8fb6e48b592507dc74c14 (diff)
downloadSMAPI-4991b4d6afea97dc6c9aa5174d438cac72e7d116.tar.gz
SMAPI-4991b4d6afea97dc6c9aa5174d438cac72e7d116.tar.bz2
SMAPI-4991b4d6afea97dc6c9aa5174d438cac72e7d116.zip
prefix OS name in log on Android
Diffstat (limited to 'src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs')
-rw-r--r--src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs b/src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs
index 2a01fe4b..c45448f3 100644
--- a/src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs
+++ b/src/SMAPI.Toolkit/Utilities/EnvironmentUtility.cs
@@ -53,7 +53,19 @@ namespace StardewModdingAPI.Toolkit.Utilities
}
catch { }
#endif
- return (platform == Platform.Mac ? "MacOS " : "") + Environment.OSVersion;
+
+ string name = Environment.OSVersion.ToString();
+ switch (platform)
+ {
+ case Platform.Android:
+ name = $"Android {name}";
+ break;
+
+ case Platform.Mac:
+ name = $"MacOS {name}";
+ break;
+ }
+ return name;
}
/// <summary>Get the name of the Stardew Valley executable.</summary>