1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-21 07:38:07 +02:00

Merge pull request #9034 from Snuffleupagus/javascript-null

[api-major] Change `getJavaScript` to return `null`, rather than an empty Array, when no JavaScript exists
This commit is contained in:
Tim van der Meij 2017-10-17 21:58:45 +02:00 committed by GitHub
commit 17cc94db4e
4 changed files with 16 additions and 8 deletions

View file

@ -683,7 +683,7 @@ describe('api', function() {
it('gets javascript', function(done) {
var promise = doc.getJavaScript();
promise.then(function (data) {
expect(data).toEqual([]);
expect(data).toEqual(null);
done();
}).catch(function (reason) {
done.fail(reason);