From f3e0281a5003a7febf0d7f03c3728ff3a507b6a1 Mon Sep 17 00:00:00 2001 From: Emmanuel Etti Date: Tue, 14 Aug 2018 13:03:16 -0300 Subject: [PATCH] Updated marbles_chaincode.js changed args[0].lenth to changed (args[0].length t --- chaincode/marbles02/node/marbles_chaincode.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/chaincode/marbles02/node/marbles_chaincode.js b/chaincode/marbles02/node/marbles_chaincode.js index 60484df0..3ee7c041 100644 --- a/chaincode/marbles02/node/marbles_chaincode.js +++ b/chaincode/marbles02/node/marbles_chaincode.js @@ -65,16 +65,16 @@ let Chaincode = class { } // ==== Input sanitation ==== console.info('--- start init marble ---') - if (args[0].lenth <= 0) { + if (args[0].length <= 0) { throw new Error('1st argument must be a non-empty string'); } - if (args[1].lenth <= 0) { + if (args[1].length <= 0) { throw new Error('2nd argument must be a non-empty string'); } - if (args[2].lenth <= 0) { + if (args[2].length <= 0) { throw new Error('3rd argument must be a non-empty string'); } - if (args[3].lenth <= 0) { + if (args[3].length <= 0) { throw new Error('4th argument must be a non-empty string'); } let marbleName = args[0];