From 2fb8a4d89fd808ef38376b6a5b6be5543ac1585c Mon Sep 17 00:00:00 2001 From: sdy623 Date: Sat, 23 Sep 2023 15:05:49 +0900 Subject: [PATCH] [Bug Fix]: "Skip NSFW" not working correctly. --- scripts/ch_lib/civitai.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ch_lib/civitai.py b/scripts/ch_lib/civitai.py index 2a15ae7..682781d 100644 --- a/scripts/ch_lib/civitai.py +++ b/scripts/ch_lib/civitai.py @@ -342,8 +342,8 @@ def get_preview_image_by_model_path(model_path:str, max_size_preview, skip_nsfw_ if model_info["images"]: for img_dict in model_info["images"]: if "nsfw" in img_dict.keys(): - if img_dict["nsfw"]: - util.printD("This image is NSFW") + if img_dict["nsfw"] != "None": + util.printD("This image is NSFW: " + str(img_dict["nsfw"])) if skip_nsfw_preview: util.printD("Skip NSFW image") continue