Fix null exception

This commit is contained in:
Jaex 2015-12-23 00:21:19 +02:00
parent 0be9b2311a
commit a5b785d69b

View file

@ -108,15 +108,18 @@ public string GetFileFormName()
{
Dictionary<string, string> arguments = new Dictionary<string, string>();
foreach (KeyValuePair<string, string> arg in Arguments)
if (Arguments != null)
{
string value = arg.Value;
foreach (KeyValuePair<string, string> arg in Arguments)
{
string value = arg.Value;
value = value.Replace("%input", "$input$"); // For backward compatibility
value = NameParser.Parse(NameParserType.Text, value);
value = value.Replace("$input$", input);
value = value.Replace("%input", "$input$"); // For backward compatibility
value = NameParser.Parse(NameParserType.Text, value);
value = value.Replace("$input$", input);
arguments.Add(arg.Key, value);
arguments.Add(arg.Key, value);
}
}
return arguments;