Skip to content
This repository was archived by the owner on Dec 11, 2019. It is now read-only.

Commit 82d1157

Browse files
committed
Check that PDF isn't already a PDFJS url
1 parent e4a0810 commit 82d1157

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

js/stores/windowStore.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ const updateNavBarInput = (loc, frameStatePath = activeFrameStatePath()) => {
5555
* @param {string=} loc - Original URL
5656
*/
5757
const setPDFLocation = (loc) => {
58-
if (loc && UrlUtil.isFileType(loc, 'pdf')) {
58+
if (loc && UrlUtil.isFileType(loc, 'pdf') && !loc.startsWith(PDFJS_ORIGIN)) {
5959
return PDFJS_ORIGIN + loc
6060
}
6161
return loc

0 commit comments

Comments
 (0)