mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-26 10:08:06 +02:00
Fix remaining linting errors, from enabling the prefer-const
ESLint rule globally
This covers cases that the `--fix` command couldn't deal with, and in a few cases (notably `src/core/jbig2.js`) the code was changed to use block-scoped variables instead.
This commit is contained in:
parent
9e262ae7fa
commit
83bdb525a4
10 changed files with 76 additions and 109 deletions
|
@ -996,8 +996,8 @@ class AESBaseCipher {
|
|||
const sourceLength = data.length;
|
||||
let buffer = this.buffer,
|
||||
bufferLength = this.bufferPosition;
|
||||
let result = [],
|
||||
iv = this.iv;
|
||||
const result = [];
|
||||
let iv = this.iv;
|
||||
|
||||
for (let i = 0; i < sourceLength; ++i) {
|
||||
buffer[bufferLength] = data[i];
|
||||
|
@ -1050,8 +1050,8 @@ class AESBaseCipher {
|
|||
|
||||
decryptBlock(data, finalize, iv = null) {
|
||||
const sourceLength = data.length;
|
||||
let buffer = this.buffer,
|
||||
bufferLength = this.bufferPosition;
|
||||
const buffer = this.buffer;
|
||||
let bufferLength = this.bufferPosition;
|
||||
// If an IV is not supplied, wait for IV values. They are at the start
|
||||
// of the stream.
|
||||
if (iv) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue