diff --git a/PluginCommon/VisBitmap8.cs b/PluginCommon/VisBitmap8.cs
index 491cd4e..fd7716c 100644
--- a/PluginCommon/VisBitmap8.cs
+++ b/PluginCommon/VisBitmap8.cs
@@ -186,7 +186,7 @@ namespace PluginCommon {
///
/// Might want a way to specify that the background shouldn't be drawn at all.
///
- /// Bitma to draw on.
+ /// Bitmap to draw on.
/// Character to draw.
/// X coord of upper-left pixel.
/// Y coord of upper-left pixel.
diff --git a/SourceGen/AppSettings.cs b/SourceGen/AppSettings.cs
index afe97ef..6daf125 100644
--- a/SourceGen/AppSettings.cs
+++ b/SourceGen/AppSettings.cs
@@ -315,6 +315,11 @@ namespace SourceGen {
/// Setting value (integer enum index).
public void SetEnum(string name, Type enumType, int value) {
string newVal = Enum.GetName(enumType, value);
+ if (newVal == null) {
+ // Shouldn't be possible if an enum value of the correct type is passed in.
+ Debug.WriteLine("Unable to get enum name type=" + enumType + " value=" + value);
+ return;
+ }
if (!mSettings.TryGetValue(name, out string oldValue) || oldValue != newVal) {
mSettings[name] = newVal;
Dirty = true;