X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fpsy%2Fpsysh%2Fsrc%2FOutput%2FShellOutput.php;fp=vendor%2Fpsy%2Fpsysh%2Fsrc%2FOutput%2FShellOutput.php;h=5881a5c20510138ea3a6473ac82487d98b4f3cef;hp=e980d38757e3001d2dbf8ca7b4540ed1ee559023;hb=0bf8d09d2542548982e81a441b1f16e75873a04f;hpb=74df008bdbb3a11eeea356744f39b802369bda3c diff --git a/vendor/psy/psysh/src/Output/ShellOutput.php b/vendor/psy/psysh/src/Output/ShellOutput.php index e980d3875..5881a5c20 100644 --- a/vendor/psy/psysh/src/Output/ShellOutput.php +++ b/vendor/psy/psysh/src/Output/ShellOutput.php @@ -41,7 +41,7 @@ class ShellOutput extends ConsoleOutput if ($pager === null) { $this->pager = new PassthruPager($this); - } elseif (is_string($pager)) { + } elseif (\is_string($pager)) { $this->pager = new ProcOutputPager($this, $pager); } elseif ($pager instanceof OutputPager) { $this->pager = $pager; @@ -65,17 +65,17 @@ class ShellOutput extends ConsoleOutput */ public function page($messages, $type = 0) { - if (is_string($messages)) { + if (\is_string($messages)) { $messages = (array) $messages; } - if (!is_array($messages) && !is_callable($messages)) { + if (!\is_array($messages) && !\is_callable($messages)) { throw new \InvalidArgumentException('Paged output requires a string, array or callback'); } $this->startPaging(); - if (is_callable($messages)) { + if (\is_callable($messages)) { $messages($this); } else { $this->write($messages, true, $type); @@ -122,15 +122,15 @@ class ShellOutput extends ConsoleOutput $messages = (array) $messages; if ($type & self::NUMBER_LINES) { - $pad = strlen((string) count($messages)); + $pad = \strlen((string) \count($messages)); $template = $this->isDecorated() ? ": %s" : "%{$pad}s: %s"; if ($type & self::OUTPUT_RAW) { - $messages = array_map(['Symfony\Component\Console\Formatter\OutputFormatter', 'escape'], $messages); + $messages = \array_map(['Symfony\Component\Console\Formatter\OutputFormatter', 'escape'], $messages); } foreach ($messages as $i => $line) { - $messages[$i] = sprintf($template, $i, $line); + $messages[$i] = \sprintf($template, $i, $line); } // clean this up for super.