Commit 629272c0 authored by m957ymj75urz's avatar m957ymj75urz
Browse files

resolve conflict with the new PreviewImage node

parent 3d2f60b3
......@@ -804,10 +804,9 @@ class SaveImage:
subfolder = os.path.dirname(filename_prefix)
filename = os.path.basename(filename_prefix)
comfy_output_folder = os.path.join(os.path.dirname(os.path.realpath(__file__)), "output")
full_output_folder = os.path.join(comfy_output_folder, subfolder)
full_output_folder = os.path.join(self.output_dir, subfolder)
if os.path.commonpath((comfy_output_folder, os.path.realpath(full_output_folder))) != comfy_output_folder:
if os.path.commonpath((self.output_dir, os.path.realpath(full_output_folder))) != self.output_dir:
print("Saving image outside the output folder is not allowed.")
return
......@@ -842,7 +841,7 @@ class SaveImage:
class PreviewImage(SaveImage):
def __init__(self):
self.output_dir = os.path.join(os.path.dirname(os.path.realpath(__file__)), "temp")
self.url_suffix = "?type=temp"
self.url_suffix = "&type=temp"
@classmethod
def INPUT_TYPES(s):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment