From 40742251ce59165bcd1aff38bbf705151e624f0c Mon Sep 17 00:00:00 2001 From: simosathan9 Date: Thu, 10 Oct 2024 22:03:52 +0300 Subject: [PATCH] Minor fixes --- public/blocks/sedBlock.js | 2 +- public/js/block.js | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/public/blocks/sedBlock.js b/public/blocks/sedBlock.js index 3afa2be..4b75701 100644 --- a/public/blocks/sedBlock.js +++ b/public/blocks/sedBlock.js @@ -49,7 +49,7 @@ var sedBlock = { tooltip: '%{BKY_SED_TOOLTIP}', helpUrl: '%{BKY_SED_HELPURL}', // URL to further information or documentation. generateCommand: function (block) { - let sedCommand = handleBlockByType(block); // Basic sed command + let sedCommand; // Handle pattern and replacement let patternBlock = block.getInputTargetBlock('regPattern'); diff --git a/public/js/block.js b/public/js/block.js index ef35930..a664ed2 100644 --- a/public/js/block.js +++ b/public/js/block.js @@ -304,9 +304,9 @@ function handleBuiltInBlocks(currentBlock) { MULTIPLY: '*', DIVIDE: '/', POWER: '^', - AND: '&&', // Logical AND - OR: '||', // Logical OR - NOT: '!' // Logical NOT + AND: '&&', + OR: '||', + NOT: '!' }; return operators[operatorField]; }; @@ -403,6 +403,7 @@ function handleBlockByType(currentBlock) { 'math_number', 'math_arithmetic', 'logic_compare', + 'logic_operation', 'controls_if' ];