Corrected after_pick() logic
This commit is contained in:
parent
958265e82b
commit
53b2dd456d
@ -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):
|
||||
if picked:
|
||||
self.print_header_stats(picked["picked"])
|
||||
else:
|
||||
self.print_header_stats(None)
|
||||
|
||||
def post(self, picked):
|
||||
try:
|
||||
|
Reference in New Issue
Block a user