From 58c763144d5381170f074336d522705b4ca93f7e Mon Sep 17 00:00:00 2001 From: cyantree - Christoph Schreiber Date: Fri, 3 Jul 2020 11:42:51 +0200 Subject: [PATCH] Support empty layers in `isValidShortKeyInternal()` which aren't the topmost layer --- src/js/game/shape_definition.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/game/shape_definition.js b/src/js/game/shape_definition.js index a521930f..33209bc9 100644 --- a/src/js/game/shape_definition.js +++ b/src/js/game/shape_definition.js @@ -220,10 +220,11 @@ export class ShapeDefinition extends BasicSerializableObject { } } - if (!anyFilled) { - // Empty layer + if (!anyFilled && i === sourceLayers.length - 1) { + // Topmost layer isn't allowed being empty return false; } + layers.push(quads); }