A couple of other script autoformatting tweaks
authorAlex Chan <alex@alexwlchan.net>
Tue, 4 Feb 2020 07:18:03 +0000 (07:18 +0000)
committerAlex Chan <alex@alexwlchan.net>
Tue, 4 Feb 2020 07:18:03 +0000 (07:18 +0000)
scripts/add_book.py
scripts/render_html.py

index b5523f3..6c73320 100755 (executable)
@@ -112,7 +112,7 @@ def get_review_info():
             ),
         ]
 
-        did_not_finish = (inquirer.prompt(questions)["did_you_finish"] == "no")
+        did_not_finish = inquirer.prompt(questions)["did_you_finish"] == "no"
 
     return {
         "date_read": date_read,
@@ -180,4 +180,5 @@ if __name__ == "__main__":
     subprocess.check_call(["open", out_path])
 
     from render_html import main
+
     main()
index 5482612..2a3d374 100755 (executable)
@@ -35,9 +35,9 @@ class Book:
 @attr.s
 class Review:
     date_read = attr.ib()
-    rating = attr.ib()
     text = attr.ib()
     format = attr.ib()
+    rating = attr.ib(default=None)
     did_not_finish = attr.ib(default=False)