From c34b3aca28f8c6ee94273d051f363bc29bcbe351 Mon Sep 17 00:00:00 2001 From: Jeff Dickey <216188+jdxcode@users.noreply.github.com> Date: Fri, 20 Apr 2018 21:00:19 -0700 Subject: [PATCH] fix: ensure name is set --- src/plugin.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugin.ts b/src/plugin.ts index 4856f039..1e966bcb 100644 --- a/src/plugin.ts +++ b/src/plugin.ts @@ -100,6 +100,7 @@ export class Plugin implements IPlugin { this._debug('reading %s plugin %s', this.type, root) this.pjson = await loadJSON(path.join(root, 'package.json')) as any this.name = this.pjson.name + if (!this.name) throw new Error(`no name in ${path.join(root, 'package.json')}`) this._debug = Debug(this.name) this.version = this.pjson.version if (this.pjson.oclif) {