Skip to content

After upgrade to 0.12.78 #4577

@dakorpar

Description

@dakorpar

Bug report

After upgrading to 0.12.78 looks like

	if ($classType->isSubclassOf(BaseRequest::class)) {
		$request = $classType->newInstance();

$request is being recognized as object instead of BaseRequest,

159 Call to an undefined method object::whatever().

works well on 0.12.77 and does not report this error.

Code snippet that reproduces the problem

	if ($classType->isSubclassOf(BaseRequest::class)) {
		$request = $classType->newInstance();
		request->whatever();

	}

https://phpstan.org/r/e1fc69b5-0542-4286-9d52-c85234392b07

ignore the first error, second one is problem

Expected output

no issue here

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions