diff --git a/gruntfile.js b/gruntfile.js index 1a9cc7ff99..bdb07dc5e3 100644 --- a/gruntfile.js +++ b/gruntfile.js @@ -147,7 +147,7 @@ module.exports = function (grunt) { rename: function (base, src) { return src.replace('/scss/', '/css/'); } - }] + }] } }, less: { @@ -159,7 +159,7 @@ module.exports = function (grunt) { rename: function (base, src) { return src.replace('/less/', '/css/'); } - }] + }] } }, 'node-inspector': { diff --git a/gulpfile.js b/gulpfile.js index f6b2e1860b..861c3b83d4 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -16,9 +16,9 @@ var _ = require('lodash'), }), path = require('path'), endOfLine = require('os').EOL, - protractor = require("gulp-protractor").protractor, - webdriver_update = require("gulp-protractor").webdriver_update, - webdriver_standalone = require("gulp-protractor").webdriver_standalone; + protractor = require('gulp-protractor').protractor, + webdriver_update = require('gulp-protractor').webdriver_update, + webdriver_standalone = require('gulp-protractor').webdriver_standalone; // Set NODE_ENV to 'test' gulp.task('env:test', function () { diff --git a/scripts/reset-password.js b/scripts/reset-password.js index fcc4f87e27..b88cd2fd17 100755 --- a/scripts/reset-password.js +++ b/scripts/reset-password.js @@ -1,3 +1,5 @@ +'use strict'; + var nodemailer = require('nodemailer'), mongoose = require('mongoose'), chalk = require('chalk'), @@ -47,7 +49,7 @@ mg.connect(function (db) { email.text = email.html = text.replace('{{name}}', user.displayName); transporter.sendMail(email, emailCallback(user)); - }; + } function emailCallback(user) { return function (err, info) { @@ -68,7 +70,7 @@ mg.connect(function (db) { return reportAndExit(processedCount, errorCount); } }; - }; + } // report the processing results and exit function reportAndExit(processedCount, errorCount) { @@ -79,7 +81,7 @@ mg.connect(function (db) { if (processedCount === 0) { console.log(chalk.yellow('No users were found.')); } else { - var alert = (!errorCount) ? chalk.green : ((successCount / processedCount) < .8) ? chalk.red : chalk.yellow; + var alert = (!errorCount) ? chalk.green : ((successCount / processedCount) < 0.8) ? chalk.red : chalk.yellow; console.log(alert('Sent ' + successCount + ' of ' + processedCount + ' emails successfully.')); }