Skip to content

Commit

Permalink
Also pass down "unknown" options to the converters from the stack con…
Browse files Browse the repository at this point in the history
…verter. Fixes #259
  • Loading branch information
rosell-dk committed Nov 9, 2020
1 parent f799005 commit 4341f30
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/Convert/Converters/Stack.php
Expand Up @@ -134,8 +134,12 @@ protected function doActualConvert()
$defaultConverterOptions = [];

foreach ($this->options2->getOptionsMap() as $id => $option) {
if ($option->isValueExplicitlySet() && !($option instanceof GhostOption)) {
//$this->logLn('hi' . $id);
// Right here, there used to be a check that ensured that unknown options was not passed down to the
// converters (" && !($option instanceof GhostOption)"). But well, as the Stack doesn't know about
// converter specific options, such as "try-cwebp", these was not passed down (see #259)
// I'm not sure why the check was made in the first place, but it does not seem neccessary, as the
// converters simply ignore unknown options. So the check has now been removed.
if ($option->isValueExplicitlySet()) {
$defaultConverterOptions[$id] = $option->getValue();
}
}
Expand Down

0 comments on commit 4341f30

Please sign in to comment.