aboutsummaryrefslogtreecommitdiff
path: root/src/app.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/app.ts')
-rw-r--r--src/app.ts9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/app.ts b/src/app.ts
index 7064d74..1994462 100644
--- a/src/app.ts
+++ b/src/app.ts
@@ -20,10 +20,13 @@ export class App {
this.logger.help();
break;
case "sync":
- await this.countries.sync({ force: true });
+ await this.countries.sync({
+ force: true,
+ flagAscii: Deno.args[1] === "flags",
+ });
break;
case "random":
- this.countries.print(this.countries.random());
+ await this.countries.print(this.countries.random());
break;
case "capital":
const [, ...args] = Deno.args;
@@ -34,7 +37,7 @@ export class App {
this.logger.log(this.countries.find(Deno.args[1]));
break;
default:
- this.countries.print(Deno.args.join(" "));
+ await this.countries.print(Deno.args.join(" "), true);
break;
}
}