NYPL research catalog translator failing
Try to import this page:
https://www.nypl.org/research/research-catalog/bib/pb9912363123506421
It looks like the shape of the JSON object assigned to the `jsonText` variable at the following link is substantially different from what the translator code expects – for example, it starts with `props.pageprops.discoveryBibResult`.
https://github.com/zotero/translators/blob/484110c925d71ec9212709ac420fa03e4f928da8/NYPL Research Catalog.js#L79
Example json payload: https://gist.github.com/telekid/20bdba1347daa6d6f1fb2068daeca72d
Also, quick question. I'm surprised that so much parsing is done with regex here:
https://github.com/zotero/translators/blob/484110c925d71ec9212709ac420fa03e4f928da8/NYPL Research Catalog.js#L141-L153
Is this for performance reasons?
https://www.nypl.org/research/research-catalog/bib/pb9912363123506421
It looks like the shape of the JSON object assigned to the `jsonText` variable at the following link is substantially different from what the translator code expects – for example, it starts with `props.pageprops.discoveryBibResult`.
https://github.com/zotero/translators/blob/484110c925d71ec9212709ac420fa03e4f928da8/NYPL Research Catalog.js#L79
Example json payload: https://gist.github.com/telekid/20bdba1347daa6d6f1fb2068daeca72d
Also, quick question. I'm surprised that so much parsing is done with regex here:
https://github.com/zotero/translators/blob/484110c925d71ec9212709ac420fa03e4f928da8/NYPL Research Catalog.js#L141-L153
Is this for performance reasons?