Fix errors reported by the no-cond-assign ESLint rule

http://eslint.org/docs/rules/no-cond-assign
This commit is contained in:
Jonas Jenwald 2016-12-10 12:33:40 +01:00
parent 00a006e466
commit fb5e756683
2 changed files with 2 additions and 2 deletions

View File

@ -2166,7 +2166,7 @@ if (typeof PDFJSDev === 'undefined' || !PDFJSDev.test('MOZCENTRAL')) {
err('\\ not allowed in relative path.'); err('\\ not allowed in relative path.');
} }
var tmp; var tmp;
if (tmp = relativePathDotMapping[buffer.toLowerCase()]) { if ((tmp = relativePathDotMapping[buffer.toLowerCase()])) {
buffer = tmp; buffer = tmp;
} }
if ('..' === buffer) { if ('..' === buffer) {

View File

@ -270,7 +270,7 @@ if (typeof PDFJS === 'undefined') {
// initialize result and counters // initialize result and counters
var bc = 0, bs, buffer, idx = 0, output = ''; var bc = 0, bs, buffer, idx = 0, output = '';
// get next character // get next character
buffer = input.charAt(idx++); (buffer = input.charAt(idx++));
// character found in table? // character found in table?
// initialize bit storage and add its ascii value // initialize bit storage and add its ascii value
~buffer && (bs = bc % 4 ? bs * 64 + buffer : buffer, ~buffer && (bs = bc % 4 ? bs * 64 + buffer : buffer,