mirror of
https://github.com/mrclay/minify.git
synced 2025-08-20 04:41:29 +02:00
closure: mute output for f5c12ad
This commit is contained in:
@@ -35,6 +35,7 @@ class Minify_ClosureCompiler
|
|||||||
{
|
{
|
||||||
const OPTION_CHARSET = 'charset';
|
const OPTION_CHARSET = 'charset';
|
||||||
const OPTION_COMPILATION_LEVEL = 'compilation_level';
|
const OPTION_COMPILATION_LEVEL = 'compilation_level';
|
||||||
|
const OPTION_WARNING_LEVEL = 'warning_level';
|
||||||
|
|
||||||
public static $isDebug = false;
|
public static $isDebug = false;
|
||||||
|
|
||||||
@@ -151,15 +152,17 @@ class Minify_ClosureCompiler
|
|||||||
array(
|
array(
|
||||||
self::OPTION_CHARSET => 'utf-8',
|
self::OPTION_CHARSET => 'utf-8',
|
||||||
self::OPTION_COMPILATION_LEVEL => 'SIMPLE_OPTIMIZATIONS',
|
self::OPTION_COMPILATION_LEVEL => 'SIMPLE_OPTIMIZATIONS',
|
||||||
|
self::OPTION_WARNING_LEVEL => 'QUIET',
|
||||||
),
|
),
|
||||||
$userOptions
|
$userOptions
|
||||||
);
|
);
|
||||||
|
|
||||||
$charsetOption = $o[self::OPTION_CHARSET];
|
$charsetOption = $o[self::OPTION_CHARSET];
|
||||||
if (preg_match('/^[\\da-zA-Z0-9\\-]+$/', $charsetOption)) {
|
if (preg_match('/^[\\da-zA-Z0-9\\-]+$/', $charsetOption)) {
|
||||||
$args[] = "--charset {$charsetOption}";
|
$args[] = "--charset {$charsetOption}";
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach (array(self::OPTION_COMPILATION_LEVEL) as $opt) {
|
foreach (array(self::OPTION_COMPILATION_LEVEL, self::OPTION_WARNING_LEVEL) as $opt) {
|
||||||
if ($o[$opt]) {
|
if ($o[$opt]) {
|
||||||
$args[] = "--{$opt} " . escapeshellarg($o[$opt]);
|
$args[] = "--{$opt} " . escapeshellarg($o[$opt]);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user