summary refs log tree commit diff
path: root/src/cdn/util/FileStorage.ts
diff options
context:
space:
mode:
authorMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2022-10-04 19:12:41 +1100
committerMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2022-10-04 19:22:50 +1100
commita3209fb7dcc251abd3196af836605fde9a018d3a (patch)
tree359063c4e858c34296ae23f7067af60b7f703215 /src/cdn/util/FileStorage.ts
parentcapture exception in sentry for embed processing (diff)
downloadserver-a3209fb7dcc251abd3196af836605fde9a018d3a.tar.xz
Video attachment support!
Diffstat (limited to '')
-rw-r--r--src/cdn/util/FileStorage.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cdn/util/FileStorage.ts b/src/cdn/util/FileStorage.ts
index 0e31a50e..9386663f 100644
--- a/src/cdn/util/FileStorage.ts
+++ b/src/cdn/util/FileStorage.ts
@@ -35,7 +35,7 @@ export class FileStorage implements Storage {
 
 	async set(path: string, value: any) {
 		path = getPath(path);
-		if (!fs.existsSync(dirname(path))) fs.mkdirSync(dirname(path));
+		if (!fs.existsSync(dirname(path))) fs.mkdirSync(dirname(path), { recursive: true });
 
 		value = Readable.from(value);
 		const cleaned_file = fs.createWriteStream(path);