Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Daniel-Pablo's avatar

Error with camel case commands - laracast generators

When I create a model -a I got this error,

Created Migration: 2020_03_15_102555_create_delinns_table                                                                     
                                                                                                                              
   Error                                                                                                                      
                                                                                                                              
  Call to undefined function Laracasts\Generators\Commands\camel_case()                                                       
                                                                                                                              
  at C:\Users\user\apps\MLM\vendor\laracasts\generators\src\Commands\SeedMakeCommand.php:39                                   
    35|      * @return string                                                                                                 
    36|      */                                                                                                               
    37|     protected function getClassName()                                                                                 
    38|     {                                                                                                                 
  > 39|         return ucwords(camel_case($this->getNameInput())) . 'TableSeeder';                                            
    40|     }                                                                                                                 
    41|                                                                                                                       
    42|     /**                                                                                                               
    43|      * Get the stub file for the generator.                                                                           
                                                                                                                              
  1   C:\Users\user\apps\MLM\vendor\laracasts\generators\src\Commands\SeedMakeCommand.php:62                                  
      Laracasts\Generators\Commands\SeedMakeCommand::getClassName()                                                           
                                                                                                                              
  2   C:\Users\user\apps\MLM\vendor\laravel\framework\src\Illuminate\Console\GeneratorCommand.php:74                          
      Laracasts\Generators\Commands\SeedMakeCommand::buildClass("App\DelinnSeeder")   

Does some one know how to fix it, I just update from laravel 6 to 7 and end up with that error run this on mi composer.JSON

"laracasts/generators": "dev-master",

That did not solve the error, thanks in advance

0 likes
4 replies

Please or to participate in this conversation.