We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 813c165 commit 3b4daceCopy full SHA for 3b4dace
src/api/apis/OpenLibraryAPI.ts
@@ -66,7 +66,7 @@ export class OpenLibraryAPI extends APIModel {
66
new BookModel({
67
title: result.title,
68
englishTitle: result.title,
69
- year: result.first_publish_year.toString(),
+ year: result.first_publish_year?.toString() ?? 'unknown',
70
dataSource: this.apiName,
71
id: result.key,
72
author: result.author_name.join(', '),
@@ -111,7 +111,7 @@ export class OpenLibraryAPI extends APIModel {
111
112
return new BookModel({
113
114
115
116
url: `https://openlibrary.org` + result.key,
117
0 commit comments