Fix pause with an await
This commit is contained in:
parent
efc73f7262
commit
541522985b
1 changed files with 3 additions and 3 deletions
|
@ -13,8 +13,8 @@ void echoMode(bool val) {
|
||||||
} catch (E) {}
|
} catch (E) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
void main(List<String> arguments) {
|
Future<void> main(List<String> arguments) async {
|
||||||
prnt('\rPress any key to continue...');
|
await prnt('\rPress any key to continue...');
|
||||||
|
|
||||||
echoMode(false);
|
echoMode(false);
|
||||||
|
|
||||||
|
@ -38,5 +38,5 @@ void main(List<String> arguments) {
|
||||||
|
|
||||||
echoMode(true);
|
echoMode(true);
|
||||||
|
|
||||||
prnt('\r\n'); // Print a newline for formatting
|
await prnt('\r\n'); // Print a newline for formatting
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue