public ICommandRepository AddCommand(ISetting command, Boolean enabled) { Commands.TryAdd(command.Name, command); if (enabled) { Settings.AddEnabled(command); } else { Settings.AddDisabled(command); } if (command is IUserCommand userCommand) { UserCommands.TryAdd(userCommand.Name, userCommand); } return(this); }