diff --git a/src/main.py b/src/main.py index 1a84495..e2f6a98 100755 --- a/src/main.py +++ b/src/main.py @@ -125,11 +125,13 @@ class YandereBot(FediBot.YandereBot): # Maybe I should remove this from the backend? def print_header_stats(self, picked): profile, frame, nsfw, path = None, None, None, None + if picked: profile = picked.profile_name frame = picked.picked_frame nsfw = picked.is_nsfw() path = picked.output_name_tr + print("Profile: {} | Frame: {} | NSFW: {} | Path: {}".format( profile, frame, nsfw, path )) @@ -151,7 +153,10 @@ class YandereBot(FediBot.YandereBot): } def after_pick(self, picked): - self.print_header_stats(picked["picked"]) + if picked: + self.print_header_stats(picked["picked"]) + else: + self.print_header_stats(None) def post(self, picked): try: