mirror of
https://github.com/gabehf/Tdarr_Plugins.git
synced 2026-03-09 07:29:04 -07:00
Small changes (#273)
This commit is contained in:
parent
1c211ad3fd
commit
3292022e86
2 changed files with 7 additions and 4 deletions
|
|
@ -4,6 +4,7 @@
|
|||
/* eslint global-require: 0 */ // --> OFF
|
||||
/* eslint import/no-extraneous-dependencies: 0 */ // --> OFF
|
||||
/* eslint no-console: 0 */ // --> OFF
|
||||
/* eslint no-param-reassign: 0 */ // --> OFF
|
||||
|
||||
// List any npm dependencies which the plugin needs, they will be auto installed when the plugin runs:
|
||||
module.exports.dependencies = [
|
||||
|
|
@ -46,7 +47,7 @@ const details = () => ({
|
|||
// eslint-disable-next-line no-unused-vars
|
||||
const plugin = (file, librarySettings, inputs, otherArguments) => {
|
||||
const lib = require('../methods/lib')();
|
||||
// eslint-disable-next-line no-unused-vars,no-param-reassign
|
||||
// load default plugin inputs
|
||||
inputs = lib.loadDefaultValues(inputs, details);
|
||||
|
||||
// Only 'require' dependencies within this function or other functions. Do not require in the top scope.
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
/* eslint global-require: 0 */ // --> OFF
|
||||
/* eslint import/no-extraneous-dependencies: 0 */ // --> OFF
|
||||
/* eslint no-console: 0 */ // --> OFF
|
||||
/* eslint no-param-reassign: 0 */ // --> OFF
|
||||
|
||||
// List any npm dependencies which the plugin needs, they will be auto installed when the plugin runs:
|
||||
module.exports.dependencies = [
|
||||
|
|
@ -71,12 +72,13 @@ const details = () => ({
|
|||
// eslint-disable-next-line no-unused-vars
|
||||
const plugin = (file, librarySettings, inputs, otherArguments) => {
|
||||
const lib = require('../methods/lib')();
|
||||
// eslint-disable-next-line no-unused-vars,no-param-reassign
|
||||
// load default plugin inputs
|
||||
inputs = lib.loadDefaultValues(inputs, details);
|
||||
|
||||
// Only 'require' dependencies within this function or other functions. Do not require in the top scope.
|
||||
const importFresh = require('import-fresh');
|
||||
|
||||
// Must return this object at some point in the function else plugin will fail.
|
||||
// Must return following object at some point in the function else plugin will fail.
|
||||
|
||||
const response = {
|
||||
processFile: false, // If set to false, the file will be skipped. Set to true to have the file transcoded.
|
||||
|
|
@ -114,7 +116,7 @@ const plugin = (file, librarySettings, inputs, otherArguments) => {
|
|||
// if so, remove it
|
||||
|
||||
response.infoLog += ' File has title metadata';
|
||||
response.preset = ',-map_metadata -1 -c:v copy -c:a copy';
|
||||
response.preset = '<io> -map_metadata -1 -c:v copy -c:a copy';
|
||||
response.processFile = true;
|
||||
return response;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue