Skip to content

Commit 6d9d84a

Browse files
committed
fix(add): use author field and push to myLibrary
1 parent 0b6299a commit 6d9d84a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

debugging/book-library/script.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ function submit() {
3737
alert("Please fill all fields!");
3838
return false;
3939
} else {
40-
let book = new Book(title.value, title.value, pages.value, check.checked);
41-
library.push(book);
40+
let book = new Book(title.value, author.value, pages.value, check.checked);
41+
myLibrary.push(book);
4242
render();
4343
}
4444
}

0 commit comments

Comments
 (0)