Skip to content

Commit

Permalink
Check for empty json response from server.
Browse files Browse the repository at this point in the history
  • Loading branch information
De-Crypted committed Aug 20, 2022
1 parent 9fd3078 commit 28f1336
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,9 @@ private async Task OnReceived(AsyncTcpClient client, int count) {
var jsonArr = jsonRaw.Split('\n').Where(str => !String.IsNullOrEmpty(str));

foreach (var json in jsonArr) {
if (string.IsNullOrEmpty(json)) {
continue;
};

if (json.Contains("\"method\"")) {
var command = JsonSerializer.Deserialize<StratumCommand>(json);
Expand Down

0 comments on commit 28f1336

Please sign in to comment.