From 9274938f9f69ecab2e8cb975467860f41466ad1d Mon Sep 17 00:00:00 2001 From: Sebastian Thiel Date: Tue, 5 May 2015 20:46:45 +0200 Subject: [PATCH] fix(CLI): completed list of parameter names Previously the 'did-you-mean' functionality only knew the global paramters, but not the method-local ones. --- src/mako/cli/lib/engine.mako | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mako/cli/lib/engine.mako b/src/mako/cli/lib/engine.mako index 099eeadf03..8c7e5009b7 100644 --- a/src/mako/cli/lib/engine.mako +++ b/src/mako/cli/lib/engine.mako @@ -259,7 +259,7 @@ ${value_unwrap}\ call = call.${ADD_PARAM_FN}(map.iter().find(|t| t.0 == key).unwrap_or(&("", key)).1, ${value_unwrap}) }, % endif # handle global parameters - _ => err.issues.push(CLIError::UnknownParameter(key.to_string(), ${field_vec(global_parameter_names)})), + _ => err.issues.push(CLIError::UnknownParameter(key.to_string(), ${field_vec(global_parameter_names + [p.name for p in optional_props])})), } } % endif # handle call parameters