From 75f18f4e06590f69d85e86bfd8d0156bd8624faa Mon Sep 17 00:00:00 2001 From: "Navy.gif" Date: Tue, 22 Mar 2022 00:46:14 +0200 Subject: [PATCH] pls work --- client/src/pages/Panel.js | 2 +- server/src/client/ClipIndex.js | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/client/src/pages/Panel.js b/client/src/pages/Panel.js index d0797ec..3b1f3d6 100644 --- a/client/src/pages/Panel.js +++ b/client/src/pages/Panel.js @@ -14,7 +14,7 @@ const Panel = () => { formData.set('name', clipname); //console.log(selectedFile) - for(const value of formData.values()) console.log('loop',value); + // for(const value of formData.values()) console.log('loop',value); const response = await fetch('/api/upload', { method: 'POST', body: formData, diff --git a/server/src/client/ClipIndex.js b/server/src/client/ClipIndex.js index e63e405..d4e6159 100644 --- a/server/src/client/ClipIndex.js +++ b/server/src/client/ClipIndex.js @@ -23,6 +23,13 @@ class ClipIndex extends EventEmitter { if (!fs.existsSync(this.videoDirectory)) fs.mkdirSync(this.videoDirectory); if (!fs.existsSync(this.thumbnailDirectory)) fs.mkdirSync(this.thumbnailDirectory); + if (process.platform === 'linux') { + // Not a particularly flexible way of doing it this way -- + // shouldn't even need to do this but for some reason it wouldn't find them with the PATH variable + ffmpeg.setFfmpegPath('/usr/bin/ffmpeg'); + ffmpeg.setFfprobePath('/usr/bin/ffprobe'); + } + this.syncIndex(); }