Net cli update on new icmp

This commit is contained in:
Djeeberjr 2022-12-19 22:57:41 +01:00
parent 0b965d32b6
commit 8180599c04

View File

@ -80,14 +80,9 @@ class Net extends CLIBase {
kernel.net.Net.instance.ping(toID).handle(result -> {
switch (result){
case Success(acc):
if (acc) {
handle.writeLn("Ping succeeded");
trigger(true);
} else {
handle.writeLn("Ping failed");
trigger(false);
}
case Success(_):
handle.writeLn("Ping succeeded");
trigger(true);
case Failure(failure):
handle.writeLn("Ping failed: " + failure);
trigger(false);