Vitaliy-1 / JATSParser

JATSParser is aimed to be integrated with Open Journal Systems 3.0+ for transforming JATS XML to various formats
GNU General Public License v3.0
11 stars 20 forks source link

CiteProc throws a fatal error if year isn't valid #24

Closed Vitaliy-1 closed 3 years ago

Vitaliy-1 commented 3 years ago

If an article isn't assigned to a journal issue, the year tag inside may be used to indicate that the article is in press, which causes a fatal error from the CiteProc:

PHP Fatal error:  Uncaught Seboettg\CiteProc\Exception\InvalidDateTimeException: Could not create valid date with year=in press, month=1, day=1. in /home/doc/OJS/development/e-med/ojs/plugins/generic/jatsParser/JATSParser/vendor/seboettg/citeproc-php/src/Rendering/Date/DateTime.php:45