Skip to content

Commit

Permalink
FIX(NodeDetails/iperf): show error if the result array is empty (#3664)
Browse files Browse the repository at this point in the history
  • Loading branch information
0oM4R authored Nov 24, 2024
1 parent b985629 commit e5dd451
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ export default {
downloadSpeed: format(node.download_speed),
uploadSpeed: format(node.upload_speed),
}));
if (array.length === 0) {
console.error("Empty array returned from the IPerf test");
throw new Error("Can't get the test results, please try again later.");
}
IperfDetails.value = array;
return IperfDetails.value;
};
Expand Down

0 comments on commit e5dd451

Please sign in to comment.