phalcon / phalcon-devtools

Phalcon Developer Tools
https://docs.phalcon.io/latest/en/devtools
Other
1.33k stars 629 forks source link

Fvromera patch fix model config namespace #1538

Closed fvromera closed 1 year ago

fvromera commented 1 year ago

Hello!

In raising this pull request, I confirm the following (please check boxes):

Small description of change:

I get this error when try to generate one model using phalcon model command:

PHP Fatal error: Uncaught TypeError: Phalcon\DevTools\Commands\Builtin\Model::getConfigObject(): Return value must be of type Phalcon\Config, Phalcon\Config\Adapter\Ini returned in /home/francis/webs/Infolot-panel.infolot.es/www/vendor/phalcon/devtools/src/Commands/Builtin/Model.php:153

This is because of namespace of Config, so we must to replace Phalcon\Config with Phalcon\Config\Config to solve it.

Thanks