From 6e22035c2740766545438cb297b0f28fa3fafb28 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Sun, 3 May 2020 13:41:36 -0700 Subject: [PATCH] Return None if no results found in first mode --- fedireads/books_manager.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fedireads/books_manager.py b/fedireads/books_manager.py index ee6941a0..9a9c1436 100644 --- a/fedireads/books_manager.py +++ b/fedireads/books_manager.py @@ -46,6 +46,8 @@ def search(query, first=False): 'results': result, }) + if first: + return None return results