fix exception being thrown in error in decl command

This commit is contained in:
Maxime Coste 2014-04-14 19:01:00 +01:00
parent 386813bbfd
commit 374f97a592

View File

@ -854,7 +854,7 @@ const CommandDesc declare_option_cmd = {
if (parser[0] == "int") if (parser[0] == "int")
opt = &opts.declare_option<int>(parser[1], docstring, 0, flags); opt = &opts.declare_option<int>(parser[1], docstring, 0, flags);
if (parser[0] == "bool") else if (parser[0] == "bool")
opt = &opts.declare_option<bool>(parser[1], docstring, 0, flags); opt = &opts.declare_option<bool>(parser[1], docstring, 0, flags);
else if (parser[0] == "str") else if (parser[0] == "str")
opt = &opts.declare_option<String>(parser[1], docstring, "", flags); opt = &opts.declare_option<String>(parser[1], docstring, "", flags);