Skip to content

Commit

Permalink
Merge pull request #344 from prabalsingh24/fix-BB-395
Browse files Browse the repository at this point in the history
fix(edition) : Cannot read property 'year' of undefined
  • Loading branch information
MonkeyDo authored Jan 21, 2020
2 parents 5edfefc + 2c59787 commit 40314ad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/server/routes/entity/edition.js
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ function transformNewForm(data) {
);

let releaseEvents = [];
if (data.editionSection.releaseDate.year) {
if (data.editionSection.releaseDate && data.editionSection.releaseDate.year) {
releaseEvents = [{date: dateObjectToISOString(data.editionSection.releaseDate)}];
}

Expand Down

0 comments on commit 40314ad

Please sign in to comment.