Making PHPStan happy
Publish PHP Package / docker (push) Successful in 6s
Details
Publish PHP Package / docker (push) Successful in 6s
Details
This commit is contained in:
parent
3bcf6c8ad2
commit
cc58754db8
|
@ -108,17 +108,14 @@ class mtgMetaInfoUnit
|
|||
public string $file;
|
||||
public mtgMetaUnit $object;
|
||||
|
||||
/**
|
||||
* @param string|mtgMetaParsedModule $file_or_module
|
||||
*/
|
||||
function __construct($file_or_module, mtgMetaUnit $obj)
|
||||
function __construct(mtgMetaParsedModule|string $file_or_module, mtgMetaUnit $obj)
|
||||
{
|
||||
if($file_or_module instanceof mtgMetaParsedModule)
|
||||
{
|
||||
$this->module = $file_or_module;
|
||||
$this->file = $file_or_module->file;
|
||||
}
|
||||
else if(is_string($file_or_module))
|
||||
else
|
||||
{
|
||||
$this->module = null;
|
||||
$this->file = $file_or_module;
|
||||
|
|
|
@ -90,6 +90,6 @@ assert($u->object->getFields()["id"]->getType() == "EnumStock");
|
|||
$u = $meta->findUnit("GameService");
|
||||
assert($u->object instanceof mtgMetaService);
|
||||
|
||||
assert($u->object->getRPC("PING") instanceof mtgMetaRPC);
|
||||
assert($u->object->getRPC("PING")->getName() == "PING");
|
||||
assert($u->object->findSymbol("DataPing") instanceof mtgMetaStruct);
|
||||
assert($u->object->findSymbol("ErrorCode") instanceof mtgMetaEnum);
|
||||
|
|
Loading…
Reference in New Issue