Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Commit

Permalink
Fixing linting errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
Oliver Beddows committed Jan 8, 2017
1 parent d37a075 commit de9cd5f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions modules/transactions.js
Original file line number Diff line number Diff line change
Expand Up @@ -190,17 +190,17 @@ __private.getById = function (id, cb) {
__private.getVotesById = function (transaction, cb) {
library.db.query(sql.getVotesById, {id: transaction.id}).then(function (rows) {
if (!rows.length) {
return setImmediate(cb, 'Transaction not found: ' + id);
return setImmediate(cb, 'Transaction not found: ' + transaction.id);
}

var votes = rows[0].votes.split(',');
var added = [];
var deleted = [];

for (var i = 0; i < votes.length; i++) {
if (votes[i].substring(0, 1) == "+") {
if (votes[i].substring(0, 1) === '+') {
added.push (votes[i].substring(1));
} else if (votes[i].substring(0, 1) == "-") {
} else if (votes[i].substring(0, 1) === '-') {
deleted.push (votes[i].substring(1));
}
}
Expand Down Expand Up @@ -406,7 +406,7 @@ shared.getTransaction = function (req, cb) {
return setImmediate(cb, 'Transaction not found');
}

if (transaction.type == 3) {
if (transaction.type === 3) {
__private.getVotesById(transaction, function (err, transaction) {
return setImmediate(cb, null, {transaction: transaction});
});
Expand Down

0 comments on commit de9cd5f

Please sign in to comment.