1.0.0-rc3 rc

This commit is contained in:
2026-05-27 12:22:32 +02:00
parent 2359c03bc8
commit 196ac2ee07
3 changed files with 74 additions and 32 deletions
+35 -18
View File
@@ -22793,6 +22793,12 @@ class PipelineService extends EventEmitter {
throw error;
}
const readyMediaProfile = this.resolveMediaProfileForJob(job, {
encodePlan: planForConfirm
});
const confirmSettings = await settingsService.getEffectiveSettingsMap(readyMediaProfile);
const settingsExtraArgsForProfile = String(confirmSettings?.handbrake_extra_args || '').trim();
// Resolve user preset: explicit payload wins, otherwise preserve currently selected preset from encode plan.
const hasUserPresetIdField = Object.prototype.hasOwnProperty.call(options || {}, 'selectedUserPresetId');
const hasHandBrakePresetField = Object.prototype.hasOwnProperty.call(options || {}, 'selectedHandBrakePreset');
@@ -22822,10 +22828,17 @@ class PipelineService extends EventEmitter {
? {
name: `HandBrake: ${rawHandBrakePreset}`,
handbrakePreset: rawHandBrakePreset,
extraArgs: ''
extraArgs: settingsExtraArgsForProfile
}
: null;
}
if (!resolvedUserPreset && explicitPresetClearRequested && settingsExtraArgsForProfile) {
resolvedUserPreset = {
name: 'Settings CLI-Parameter',
handbrakePreset: null,
extraArgs: settingsExtraArgsForProfile
};
}
if (!resolvedUserPreset && !explicitPresetClearRequested) {
resolvedUserPreset = normalizeUserPresetForPlan(
planForConfirm?.userPreset || encodePlan?.userPreset || null
@@ -22850,10 +22863,6 @@ class PipelineService extends EventEmitter {
reviewConfirmedAt: nowIso(),
userPreset: normalizeUserPresetForPlan(resolvedUserPreset)
};
const readyMediaProfile = this.resolveMediaProfileForJob(job, {
encodePlan: confirmedPlan
});
const confirmSettings = await settingsService.getEffectiveSettingsMap(readyMediaProfile);
const confirmedConverterMediaType = String(
confirmedPlan?.converterMediaType || encodePlan?.converterMediaType || ''
).trim().toLowerCase();
@@ -22878,19 +22887,27 @@ class PipelineService extends EventEmitter {
|| encodePlan?.selectors?.extraArgs
|| ''
).trim();
const effectivePresetName = String(
resolvedUserPreset?.handbrakePreset
|| rawHandBrakePreset
|| planPresetName
|| confirmSettings?.handbrake_preset
|| ''
).trim();
const effectiveExtraArgs = String(
resolvedUserPreset?.extraArgs
|| planExtraArgs
|| confirmSettings?.handbrake_extra_args
|| ''
).trim();
const effectivePresetName = explicitPresetClearRequested
? ''
: String(
resolvedUserPreset?.handbrakePreset
|| rawHandBrakePreset
|| planPresetName
|| confirmSettings?.handbrake_preset
|| ''
).trim();
const effectiveExtraArgs = explicitPresetClearRequested
? String(
resolvedUserPreset?.extraArgs
|| settingsExtraArgsForProfile
|| ''
).trim()
: String(
resolvedUserPreset?.extraArgs
|| planExtraArgs
|| settingsExtraArgsForProfile
|| ''
).trim();
if (requiresExplicitPreset && !effectivePresetName && !effectiveExtraArgs) {
const error = new Error('Bestätigung nicht möglich: Kein Preset oder Extra-Args gesetzt. Bitte User-/HandBrake-Preset wählen oder passende Settings hinterlegen.');
error.statusCode = 400;