context_wrap options are allowed only at start
This commit is contained in:
parent
d3961768ec
commit
21f487417b
|
@ -532,7 +532,7 @@ template<typename Func>
|
||||||
void context_wrap(const CommandParameters& params, Context& context, Func func)
|
void context_wrap(const CommandParameters& params, Context& context, Func func)
|
||||||
{
|
{
|
||||||
ParametersParser parser(params, { { "client", true }, { "draft", false }},
|
ParametersParser parser(params, { { "client", true }, { "draft", false }},
|
||||||
ParametersParser::Flags::None, 1);
|
ParametersParser::Flags::OptionsOnlyAtStart, 1);
|
||||||
|
|
||||||
Context& real_context = parser.has_option("client") ?
|
Context& real_context = parser.has_option("client") ?
|
||||||
ClientManager::instance().get_client(parser.option_value("client")).context()
|
ClientManager::instance().get_client(parser.option_value("client")).context()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user