Laravel 4: PHP Fatal error: call to undefined method Blueprint :: int ()

I have compiled a new installation of Laravel 4, and I get this error after I create a migration and try to transfer it through artisan:

PHP Fatal error: calling the undefined method Illuminate \ Database \ Schema \ Blueprint :: int () in /home/casey/Sites/caseyhoffmann.me/laravel4/app/database/migrations/2013_10_22_232234_create_users_table.php on line 22 {"error": {"type": "Symfony \ Component \ Debug \ Exception \ FatalErrorException", "message": "Call the undefined method Illuminate \ Database \ Schema \ Blueprint :: int ()", "file": "/ main / Casey / Sites /caseyhoffmann.me/laravel4/appendix/databases / migration / 2013_10_22_232234_create_users_table.php "," line ": 22}}

I tried recompiling Laravel, but to no avail.

Any ideas or suggestions?

+7
php undefined fatal-error laravel laravel-4
source share
1 answer

Your int () should be replaced with integer() in the migration file. Like this:

$table->integer('user_id');

+22
source share

All Articles