Skip to content

Commit 9ea093d

Browse files
committed
[eslint] more fixes of the merged files
1 parent 1fc2135 commit 9ea093d

File tree

25 files changed

+8361
-7743
lines changed

25 files changed

+8361
-7743
lines changed

Gruntfile.js

+20-20
Original file line numberDiff line numberDiff line change
@@ -202,21 +202,21 @@ module.exports = function(grunt) {
202202
},
203203
src: ['test/*/*.js']
204204
}
205-
},
206-
mocha_nyc: {
205+
},
206+
mocha_nyc: {
207207
coverage: {
208208
src: ['test/*/*.js'], // a folder works nicely
209209
options: {
210-
coverage:true, // this will make the grunt.event.on('coverage') event listener to be triggered
210+
coverage: true, // this will make the grunt.event.on('coverage') event listener to be triggered
211211
mask: '*.js',
212212
excludes: ['bin/*', 'frontend/*', 'extend/*', 'Gruntfile.js', 'test/*'],
213-
mochaOptions: ['--harmony', '--async-only', '--reporter', 'spec', '--timeout', '50000', '--exit'],
214-
nycOptions: ['--harmony', '--clean', 'false'],//,'--include-all-sources' '--all'
215-
reportFormats: ['none']
213+
mochaOptions: ['--harmony', '--async-only', '--reporter', 'spec', '--timeout', '50000', '--exit'],
214+
nycOptions: ['--harmony', '--clean', 'false'], //,'--include-all-sources' '--all'
215+
reportFormats: ['none']
216216
}
217217
}
218-
},
219-
istanbul_check_coverage: {
218+
},
219+
istanbul_check_coverage: {
220220
default: {
221221
options: {
222222
coverageFolder: 'coverage*', // will check both coverage folders and merge the coverage results
@@ -229,15 +229,15 @@ module.exports = function(grunt) {
229229
}
230230
});
231231

232-
//code coverage
233-
grunt.event.on('coverage', function(lcovFileContents, done){
234-
// Check below on the section "The coverage event"
235-
done();
236-
});
237-
grunt.loadNpmTasks('grunt-mocha-nyc');
238-
grunt.registerTask('coverage', ['mocha_nyc:coverage']);
239-
//-----------code coverage-----------
240-
232+
//code coverage
233+
grunt.event.on('coverage', function(lcovFileContents, done) {
234+
// Check below on the section "The coverage event"
235+
done();
236+
});
237+
grunt.loadNpmTasks('grunt-mocha-nyc');
238+
grunt.registerTask('coverage', ['mocha_nyc:coverage']);
239+
//-----------code coverage-----------
240+
241241
grunt.loadNpmTasks('grunt-contrib-jshint');
242242
grunt.loadNpmTasks('grunt-contrib-concat');
243243
grunt.loadNpmTasks('grunt-contrib-uglify');
@@ -264,8 +264,8 @@ module.exports = function(grunt) {
264264
plugins.push('push_approver');
265265
}
266266
}
267-
268-
if (plugins.indexOf('drill') !== -1) {
267+
268+
if (plugins.indexOf('drill') !== -1) {
269269
if (plugins.indexOf('cohorts') !== -1) {
270270
plugins.splice(plugins.indexOf('cohorts'), 1);
271271
plugins.push('cohorts');
@@ -407,4 +407,4 @@ module.exports = function(grunt) {
407407

408408
grunt.registerTask('dist-all', ['dist', 'plugins', 'locales']);
409409

410-
};
410+
};

extend/mail.example.js

+6-5
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,19 @@ module.exports = function(mail) {
1818
pass: "password"
1919
}
2020
}));
21-
21+
2222
mail.sendMail = function(message, callback) {
23-
message.from = company+" <"+email+">";
24-
mail.smtpTransport.sendMail(message, function (error) {
23+
message.from = company + " <" + email + ">";
24+
mail.smtpTransport.sendMail(message, function(error) {
2525
if (error) {
2626
console.log('Error sending email');
2727
console.log(error.message);
2828
}
29-
if(callback)
29+
if (callback) {
3030
callback(error);
31+
}
3132
});
32-
}
33+
};
3334

3435
mail.sendMessage = function(to, subject, message, callback) {
3536
mail.sendMail({

plugins/assistant/frontend/public/javascripts/countly.views.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ window.AssistantView = {
3131
var notificationButtonID = "#notification-icon";
3232
var data = countlyAssistant.getDataForApp(countlyCommon.ACTIVE_APP_ID);
3333

34-
if(data.notifications === null || typeof data.notifications === "undefined"){
34+
if (data.notifications === null || typeof data.notifications === "undefined") {
3535
//if this is null, assume that everything else is also
3636
//todo fix the circumstances that cause these cases
3737
data.notifications = [];

plugins/browser/tests.js

+5-5
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ describe('Testing Browser metrics', function() {
2323
}
2424
var ob = JSON.parse(res.text);
2525
ob.should.be.empty;
26-
done();
26+
done();
2727
});
2828
});
2929
});
@@ -39,7 +39,7 @@ describe('Testing Browser metrics', function() {
3939
}
4040
var ob = JSON.parse(res.text);
4141
ob.should.have.property('result', 'Success');
42-
setTimeout(done, 300 * testUtils.testScalingFactor)
42+
setTimeout(done, 300 * testUtils.testScalingFactor);
4343
});
4444
});
4545
});
@@ -72,7 +72,7 @@ describe('Testing Browser metrics', function() {
7272
}
7373
var ob = JSON.parse(res.text);
7474
ob.should.have.property('result', 'Success');
75-
setTimeout(done, testUtils.testWaitTimeForDrillEvents * testUtils.testScalingFactor)
75+
setTimeout(done, testUtils.testWaitTimeForDrillEvents * testUtils.testScalingFactor);
7676
});
7777
});
7878
});
@@ -98,7 +98,7 @@ describe('Testing Browser metrics', function() {
9898
}
9999
var ob = JSON.parse(res.text);
100100
ob.should.have.property('result', 'Success');
101-
setTimeout(done, 10 * testUtils.testScalingFactor)
101+
setTimeout(done, 10 * testUtils.testScalingFactor);
102102
});
103103
});
104104
});
@@ -113,7 +113,7 @@ describe('Testing Browser metrics', function() {
113113
}
114114
var ob = JSON.parse(res.text);
115115
ob.should.be.empty;
116-
done();
116+
done();
117117
});
118118
});
119119
});

0 commit comments

Comments
 (0)