Update repository type handling in verbose output

This commit is contained in:
netkas 2024-09-19 00:31:57 -04:00
parent 943048785d
commit da8a6fac01
3 changed files with 2 additions and 3 deletions

View file

@ -119,7 +119,7 @@
throw new InvalidArgumentException(sprintf('The remote source \'%s\' already exists', $source->getName()));
}
Console::outVerbose(sprintf('Adding repository \'%s\' as %s (type: %s)', $source->getHost(), $source->getName(), $source->getType()));
Console::outVerbose(sprintf('Adding repository \'%s\' as %s (type: %s)', $source->getHost(), $source->getName(), $source->getType()->value));
$this->repositories[] = $source;
if($update)

View file

@ -116,7 +116,6 @@
$repository = Repository::fromArray($repository);
}
return new self($source, $repository);
}
}

View file

@ -224,7 +224,7 @@
{
return [
($bytecode ? Functions::cbc('name') : 'name') => $this->name,
($bytecode ? Functions::cbc('type') : 'type') => ($this->type ? null : $this->type->value),
($bytecode ? Functions::cbc('type') : 'type') => ($this->type?->value),
($bytecode ? Functions::cbc('host') : 'host') => $this->host,
($bytecode ? Functions::cbc('ssl') : 'ssl') => $this->ssl
];