From 47864c4c39abb33d04dcb5ceba9e8e304d6cbf79 Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Wed, 13 Jun 2018 17:20:09 -0400 Subject: [PATCH] use hasKey helper --- src/program.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/program.ts b/src/program.ts index 3ff128ef5c8..6ac57045667 100644 --- a/src/program.ts +++ b/src/program.ts @@ -565,8 +565,8 @@ export class Program { private async exitIfLocked() { await this.exitIfNotAuthed(); - const key = await this.main.cryptoService.getKey(); - if (key == null) { + const hasKey = await this.main.cryptoService.hasKey(); + if (!hasKey) { this.processResponse(Response.error('Vault is locked.')); } }