fix connect command issue

This commit is contained in:
2022-12-10 17:53:26 +08:00
parent 59af1e468d
commit a8a0a14713

View File

@ -207,7 +207,9 @@ namespace GrasscutterTools.Forms
{
Logger.I(TAG, $"SetCommand(\"{command}\")");
var oldCommand = CmbCommand.Text;
CmbCommand.Text = (ModifierKeys == Keys.Shift) ? $"{oldCommand} | {command}" : command;
CmbCommand.Text = (ModifierKeys == Keys.Shift) ?
(string.IsNullOrEmpty(oldCommand) ? command : $"{oldCommand} | {command}")
: command;
if (ChkAutoCopy.Checked)
CopyCommand();
AddCommandToList(command);