Skip to content

Commit 28ae377

Browse files
committed
Removed unnecessary code
1 parent 11bf342 commit 28ae377

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed
0 Bytes
Binary file not shown.

python-sqlite-sqlalchemy/project/examples/example_2/main.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -123,10 +123,6 @@ def add_new_book(session, author_name, book_title, publisher_name):
123123
author = Author(first_name=first_name, last_name=last_name)
124124
session.add(author)
125125

126-
# Is this a new book for this author?
127-
if book not in [book_ for book_ in author.books]:
128-
author.books.append(book)
129-
130126
# Get the publisher
131127
publisher = (
132128
session.query(Publisher)

0 commit comments

Comments
 (0)