From 2907329c20c82384c20a2ad701221048954ae915 Mon Sep 17 00:00:00 2001 From: Brett Logan Date: Mon, 8 Feb 2021 09:54:50 -0500 Subject: [PATCH] Fix Linting and Enable ES6 Syntax Fix a small linting issue and add the es6 tag to handle the return of a Promise as it is not defined in the ECMA spec. Signed-off-by: Brett Logan --- asset-transfer-events/application-javascript/.eslintrc.js | 3 ++- asset-transfer-events/application-javascript/app.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/asset-transfer-events/application-javascript/.eslintrc.js b/asset-transfer-events/application-javascript/.eslintrc.js index 8422f8a8..ae0bf212 100644 --- a/asset-transfer-events/application-javascript/.eslintrc.js +++ b/asset-transfer-events/application-javascript/.eslintrc.js @@ -6,7 +6,8 @@ module.exports = { env: { node: true, - mocha: true + mocha: true, + es6: true }, parserOptions: { ecmaVersion: 8, diff --git a/asset-transfer-events/application-javascript/app.js b/asset-transfer-events/application-javascript/app.js index 4a8a1c2f..0f12a385 100644 --- a/asset-transfer-events/application-javascript/app.js +++ b/asset-transfer-events/application-javascript/app.js @@ -320,7 +320,7 @@ async function main() { } catch (deleteError) { console.log(`${RED}<-- Failed: DeleteAsset - ${deleteError}${RESET}`); if (deleteError.toString().includes('ENDORSEMENT_POLICY_FAILURE')) { - console.log(`${RED}Be sure that chaincode was deployed with the endorsement policy "OR('Org1MSP.peer','Org2MSP.peer')"${RESET}`) + console.log(`${RED}Be sure that chaincode was deployed with the endorsement policy "OR('Org1MSP.peer','Org2MSP.peer')"${RESET}`); } } try {