Skip to content

New strange error "Cannot call method getInputHtml() on class-string|object." #4579

@williamdes

Description

@williamdes

Bug report

Strange new error since .78 version

And the code checks if (method_exists($transformation_plugin, 'getInputHtml')) { so for me it can not be a class-string at this point 🤔

Code snippet that reproduces the problem

https://github.com/phpmyadmin/phpmyadmin/blob/58c4f3fe16f17400436946be9a82b5811439107b/libraries/classes/InsertEdit.php#L3444

https://github.com/phpmyadmin/phpmyadmin/blob/58c4f3fe16f17400436946be9a82b5811439107b/libraries/classes/InsertEdit.php#L3459

Expected output

no errors

Actual output

$ composer run phpstan > phpstan analyse Note: Using configuration file phpstan.neon.dist. 733/733 [▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓] 100% ------ ----------------------------------------------------------- Line libraries/classes/InsertEdit.php ------ ----------------------------------------------------------- 3444 Cannot call method getInputHtml() on class-string|object. 3459 Cannot call method getScripts() on class-string|object. ------ ----------------------------------------------------------- 

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