Add default case for SquirrelContext switch (#716)

Add default case for SquirrelContext switch and logs errors so we can catch them if they do ever happen.
This commit is contained in:
Jan 2024-06-16 17:57:52 +02:00 committed by GitHub
parent f75aff1425
commit 75bb4143ce
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -601,6 +601,8 @@ auto ModConCommandCallback(const CCommand& command)
case ScriptContext::UI:
ModConCommandCallback_Internal<ScriptContext::UI>(found->Function, command);
break;
default:
spdlog::error("ModConCommandCallback on invalid Context {}", found->Context);
};
}