From 2c26bf369221fa52072c6488b3da034bc4beeee9 Mon Sep 17 00:00:00 2001 From: HaveAGitGat <43864057+HaveAGitGat@users.noreply.github.com> Date: Fri, 29 Nov 2019 19:29:24 +0000 Subject: [PATCH] [New] Action: Remux container --- methods/library/actions/remuxContainer.js | 38 +++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 methods/library/actions/remuxContainer.js diff --git a/methods/library/actions/remuxContainer.js b/methods/library/actions/remuxContainer.js new file mode 100644 index 0000000..42621c2 --- /dev/null +++ b/methods/library/actions/remuxContainer.js @@ -0,0 +1,38 @@ + + +function remuxContainer(file, container) { + + try { + + + if (file.container != container) { + + var response = { + processFile: true, + note:`File is not in ${container} \\n` + } + return response + + } else { + + var response = { + processFile: false, + note:`File is already in ${container} \\n` + } + return response + + } + + + + } catch (err) { + var response = { + processFile: false, + note:`library.actions.remuxContainer error: ${err.stack} \\n` + } + return response + } +} + + +module.exports = remuxContainer \ No newline at end of file