Removed some useless code

This commit is contained in:
Kwoth
2022-02-07 17:52:57 +01:00
parent 0008eabdd2
commit 1622eb05c9
5 changed files with 15 additions and 21 deletions

View File

@@ -111,11 +111,10 @@ namespace NadekoBot.Coordinator
return new DieReply();
}
public override async Task<SetConfigTextReply> SetConfigText(SetConfigTextRequest request, ServerCallContext context)
public override Task<SetConfigTextReply> SetConfigText(SetConfigTextRequest request, ServerCallContext context)
{
await Task.Yield();
string error = string.Empty;
bool success = true;
var error = string.Empty;
var success = true;
try
{
_runner.SetConfigText(request.ConfigYml);
@@ -126,11 +125,11 @@ namespace NadekoBot.Coordinator
success = false;
}
return new(new()
return Task.FromResult<SetConfigTextReply>(new(new()
{
Success = success,
Error = error
});
}));
}
public override Task<GetConfigTextReply> GetConfigText(GetConfigTextRequest request, ServerCallContext context)