From 5f0bc83d677ba6c08c9c89761117c025930c775c Mon Sep 17 00:00:00 2001 From: estevez-dev Date: Tue, 3 Sep 2019 23:58:28 +0300 Subject: [PATCH] Resolves #439 Fix negative and zero columns issue for glance card --- lib/ui_class/card.class.dart | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/ui_class/card.class.dart b/lib/ui_class/card.class.dart index f6a2e67..ecc1dfd 100644 --- a/lib/ui_class/card.class.dart +++ b/lib/ui_class/card.class.dart @@ -29,7 +29,11 @@ class HACard { this.states, this.conditions: const [], @required this.type - }); + }) { + if (this.columnsCount <= 0) { + this.columnsCount = 4; + } + } List getEntitiesToShow() { return entities.where((entityWrapper) {