Skip to content

Commit

Permalink
🐞Fix: Stable Diffusion User Directory (danny-avila#2270)
Browse files Browse the repository at this point in the history
  • Loading branch information
bsu3338 authored Apr 1, 2024
1 parent 5c8b16f commit 038063d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/app/clients/tools/structured/StableDiffusion.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,8 @@ class StableDiffusionAPI extends StructuredTool {
const filepath = path.join(imageOutputPath, this.userId, imageName);
this.relativePath = path.relative(clientPath, imageOutputPath);

if (!fs.existsSync(imageOutputPath)) {
fs.mkdirSync(imageOutputPath, { recursive: true });
if (!fs.existsSync(path.join(imageOutputPath, this.userId))) {
fs.mkdirSync(path.join(imageOutputPath, this.userId), { recursive: true });
}

try {
Expand Down

0 comments on commit 038063d

Please sign in to comment.