Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[fix] Fixes for JShint compliance in event listeners.

  • Loading branch information...
commit 43fc5d8eee4b67cca0319d2b92a99604e160a6f8 1 parent 82ac1e4
Charlie McConnell AvianFlu authored
Showing with 6 additions and 6 deletions.
  1. +5 −5 lib/listeners/beer.js
  2. +1 −1  lib/listeners/twitter.js
10 lib/listeners/beer.js
View
@@ -1,4 +1,4 @@
-/*
+/*
*
* listeners/beer.js - Event listener for IRC events, providing you with cold
* beer
@@ -14,21 +14,21 @@ var beer = module.exports = function () {
self.preferences = self.config.get('karma:preferences') || {};
self.on('*::gotMessage', function (data) {
- var re = /^[\+-]?(\w+)([:, ]){0,3}(\+\+|--)/,
+ var re = /^[\+\-]?(\w+)([:, ]){0,3}(\+\+|--)/,
res;
if (res = re.exec(data.text)) {
- if (res[1] == data.nick) {
+ if (res[1] === data.nick) {
return self.emit('sendMsg', {
dest: data.to,
msg: "You can't give karma to yourself!"
});
}
self.karma[res[1]] || (self.karma[res[1]] = 0);
- if (res[3] == '++') {
+ if (res[3] === '++') {
++self.karma[res[1]];
}
- else if (res[3] == '--') {
+ else if (res[3] === '--') {
--self.karma[res[1]];
}
2  lib/listeners/twitter.js
View
@@ -20,4 +20,4 @@ var twitter = module.exports = function () {
self.on('*::blocked', function (data) {
self.emit('sendMsg', {dest: data.to, msg: 'I have blocked ' + data.name + '.'});
});
-}
+};
Please sign in to comment.
Something went wrong with that request. Please try again.