Remove non-standard syntax for conditional exception handling
This commit is contained in:
parent
39bc5398c9
commit
54a2126b7d
1 changed files with 4 additions and 2 deletions
|
@ -74,8 +74,10 @@ function ZoteroProtocolHandler() {
|
|||
Zotero.API.Data.getGenerator(path)
|
||||
);
|
||||
}
|
||||
catch (e if e instanceof Zotero.Router.InvalidPathException) {
|
||||
return "URL could not be parsed";
|
||||
catch (e) {
|
||||
if (e instanceof Zotero.Router.InvalidPathException) {
|
||||
return "URL could not be parsed";
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue