Change the casing of the originalURL parameter, to originalUrl, in the onOpenWithURL method

The `onOpenWithURL` method, in `PDFViewerApplication.initPassiveLoading`, accepts a `originalURL` parameter which is then passed on to `PDFViewerApplication.open` as is. However, the latter method expects the name of the parameter to be `originalUrl` (note the casing), meaning that `getDocument` will fail in this case.

For consistency, and to avoid confusion, the renaming is done in `web/chromecom.js` as well.
This commit is contained in:
Jonas Jenwald 2018-06-17 13:25:22 +02:00
parent 620da6f4df
commit 84920f39b2
2 changed files with 8 additions and 8 deletions

View file

@ -593,13 +593,13 @@ let PDFViewerApplication = {
onOpenWithData(data) {
PDFViewerApplication.open(data);
},
onOpenWithURL(url, length, originalURL) {
onOpenWithURL(url, length, originalUrl) {
let file = url, args = null;
if (length !== undefined) {
args = { length, };
}
if (originalURL !== undefined) {
file = { url, originalURL, };
if (originalUrl !== undefined) {
file = { url, originalUrl, };
}
PDFViewerApplication.open(file, args);
},