Correct book counting.

This commit is contained in:
Michael Gregson 2009-03-11 02:02:17 -04:00
parent bf98adc034
commit 1d7f739631
1 changed files with 1 additions and 1 deletions

View File

@ -131,7 +131,7 @@ class BookAddPage(WizardPanel):
book = pymazon.lookup(isbn)
currents = lib.Book.select(lib.Book.q.isbn==isbn)
if len(currents) == 0:
if currents.count() == 0:
lib.Book(isbn=isbn, title=book.title,
year=book.year, publisher=book.publisher)
else: