From 1bd79064020c09910d9b151d9b633c01ce4a972b Mon Sep 17 00:00:00 2001 From: Neel Kamath Date: Sun, 13 May 2018 15:48:46 +0530 Subject: Use the 'use strict' directive when needed --- README.md | 1 + server/src/scripts/configure.js | 2 ++ server/src/scripts/debug.js | 2 ++ server/src/scripts/dev.js | 2 ++ 4 files changed, 7 insertions(+) diff --git a/README.md b/README.md index 6e72a08..4a68ce6 100644 --- a/README.md +++ b/README.md @@ -40,6 +40,7 @@ This is a backwards compatible continuation of the [work by Andrew Belt](https:/ - Use [the template](templateCommand.js) to learn how to create new commands. - Use two space indents. - Name files in camelCase. +- Scripts that do not default to strict mode (such as modules) must use the `'use strict'` directive. # Credits diff --git a/server/src/scripts/configure.js b/server/src/scripts/configure.js index 88cd098..0ecd858 100644 --- a/server/src/scripts/configure.js +++ b/server/src/scripts/configure.js @@ -7,6 +7,8 @@ * */ +'use strict'; + // import required classes const path = require('path'); const ImportsManager = require('../managers/imports-manager'); diff --git a/server/src/scripts/debug.js b/server/src/scripts/debug.js index 97597cd..3a97d9f 100644 --- a/server/src/scripts/debug.js +++ b/server/src/scripts/debug.js @@ -7,6 +7,8 @@ * */ +'use strict'; + // import required classes const path = require('path'); const ConfigManager = require('../managers/config'); diff --git a/server/src/scripts/dev.js b/server/src/scripts/dev.js index f1608ed..5049b84 100644 --- a/server/src/scripts/dev.js +++ b/server/src/scripts/dev.js @@ -7,6 +7,8 @@ * */ +'use strict'; + // import required classes -- cgit v1.2.1