1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-26 01:58:06 +02:00

Removes error()

This commit is contained in:
Yury Delendik 2017-06-28 13:51:31 -07:00
parent ac9802809c
commit d028c26210
24 changed files with 318 additions and 260 deletions

View file

@ -14,7 +14,7 @@
*/
import {
assert, error, info, isArray, isArrayBuffer, isNum, isSpace, isString,
assert, info, isArray, isArrayBuffer, isNum, isSpace, isString,
MissingDataException, OPS, shadow, stringToBytes, stringToPDFString, Util,
warn
} from '../shared/util';
@ -353,7 +353,7 @@ var PDFDocument = (function PDFDocumentClosure() {
} else if (isArrayBuffer(arg)) {
stream = new Stream(arg);
} else {
error('PDFDocument: Unknown argument type');
throw new Error('PDFDocument: Unknown argument type');
}
assert(stream.length > 0, 'stream must have data');