From 647d562e2c5dff4afbfe44bbf4e8f948e35ad34a Mon Sep 17 00:00:00 2001 From: Brian White Date: Tue, 11 Sep 2012 11:52:23 -0400 Subject: [PATCH] More style changes --- lib/imap.parsers.js | 22 +++++++++++----------- lib/mimeparser.js | 2 +- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/lib/imap.parsers.js b/lib/imap.parsers.js index 2d8c3ef..5b2ccb8 100644 --- a/lib/imap.parsers.js +++ b/lib/imap.parsers.js @@ -14,14 +14,14 @@ exports.convStr = function(str, literals) { return literals[literals.lp++]; else return str; -} +}; exports.parseNamespaces = function(str, literals) { var result, vals; if (str.length === 3 && str.toUpperCase() === 'NIL') vals = null; else { - result = exports.parseExpr(str, literals) + result = exports.parseExpr(str, literals); vals = []; for (var i=0,len=result.length; i next && Array.isArray(cur[next])) { part.envelope = {}; - for (var i=0,field,len=cur[next].length; i next) { @@ -242,13 +242,13 @@ exports.parseStructExtra = function(part, partLen, cur, next) { // let's not parse it for now ... part.extensions = cur[next]; } -} +}; -function isAlpha(ch) { +/*function isAlpha(ch) { if (typeof ch === 'string') ch = ch.charCodeAt(0); return ((ch >= 65 && ch <= 90) || (ch >= 97 && ch <= 122)); -} +}*/ exports.parseExpr = function(o, literals, result, start) { start = start || 0; @@ -284,4 +284,4 @@ exports.parseExpr = function(o, literals, result, start) { result.push(exports.convStr(o.str.substring(lastPos+1), literals)); } return (isTop ? result : start); -} +}; diff --git a/lib/mimeparser.js b/lib/mimeparser.js index 51d857c..ba36137 100644 --- a/lib/mimeparser.js +++ b/lib/mimeparser.js @@ -18,7 +18,7 @@ var MIMEParser = module.exports = function() { inherits(MIMEParser, EventEmitter); MIMEParser.prototype.execute = function(b, start, end) { - if (this._state == PARSE_BODY) { + if (this._state === PARSE_BODY) { var chunk; if ((start === undefined && end === undefined) || (start === 0 && end === b.length))