Update PHPDOC colors

This commit is contained in:
Maarten 2019-12-24 02:25:59 +01:00
parent f56bc7952a
commit 032d8ff101

View file

@ -48,22 +48,22 @@ trait Colors {
/**
* @param $string
* @param null $foreground_color
* @param null $background_color
* @param null $foreground
* @param null $background
* @return string
*/
public function printColor($string, $foreground_color = null, $background_color = null)
public function printColor($string, $foreground = null, $background = null)
{
$this->setColors();
$colored_string = "";
if (isset($this->foreground_colors[$foreground_color])) {
$colored_string .= "\033[" . $this->foreground_colors[$foreground_color] . "m";
if (isset($this->foreground_colors[$foreground])) {
$colored_string .= "\033[" . $this->foreground_colors[$foreground] . "m";
}
if (isset($this->background_colors[$background_color])) {
$colored_string .= "\033[" . $this->background_colors[$background_color] . "m";
if (isset($this->background_colors[$background])) {
$colored_string .= "\033[" . $this->background_colors[$background] . "m";
}