&1 | grep "'.self::PACKAGE_STATUS.'")', $output); if (isset($output[0]) && $output[0] === self::PACKAGE_STATUS) { $result = true; } return $result; } /** * apt add a Warning for no good, * * * @return array */ public function filterAptMessages($output) { $results = []; foreach($output as $message) { if (!in_array($message, self::NOT_ALLOWED) && !empty($message)) { $results[] = $message; } } return $results; } }