From 939afa9822c0d777e3453ff1d6d984d99f671f80 Mon Sep 17 00:00:00 2001 From: Tomas Novella Date: Sun, 9 Dec 2018 09:40:49 +0100 Subject: [PATCH] Fix compile error in TS Without a type annotation, TS expects the argument in the ctor to be a never[], hence "npm test" fails to even start --- TypeScript/app/gilded-rose.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TypeScript/app/gilded-rose.ts b/TypeScript/app/gilded-rose.ts index c7d58c65..928aa579 100644 --- a/TypeScript/app/gilded-rose.ts +++ b/TypeScript/app/gilded-rose.ts @@ -13,7 +13,7 @@ export class Item { export class GildedRose { items: Array; - constructor(items = []) { + constructor(items = [] as Array) { this.items = items; }