mardi 25 août 2015

PHP artisan suddenly doesen't work

I have started to learning Laravel. Until now, everything worked perfectly. I'm following this tutorial and I'm stuck with episode 7: http://ift.tt/1ydCEuC

Problem is that I cannot start artisan any more. I have tried to install tinker, and i probably updated artisan so I ended without artisan and tinker. I am using Linux Ubuntu 12.04 LTS. I have installed everything via command line. After I try to run:

php artisan --version

the problem occurs:

[ErrorException]
Declaration of App\Providers\EventServiceProvider::boot() should be compati ble with Illuminate\Foundation\Support\Providers\EventServiceProvider::boot
()

This is how my file app/Providers/EventServiceProvider.php looks like:

<?php

namespace App\Providers;

use Illuminate\Contracts\Events\Dispatcher as DispatcherContract;
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;

class EventServiceProvider extends ServiceProvider
{
    /**
     * The event listener mappings for the application.
     *
     * @var array
     */
    protected $listen = [
        'App\Events\SomeEvent' => [
            'App\Listeners\EventListener',
        ],
    ];

    /**
     * Register any other events for your application.
     *
     * @param  \Illuminate\Contracts\Events\Dispatcher  $events
     * @return void
     */
    public function boot(DispatcherContract $events)
    {
        parent::boot($events);

        //
    }
}

I'm using Laravel 5.2 and in my composer.json it looks like this:

"php": ">=5.5.9",
"laravel/framework": "5.2.*",
"doctrine/dbal": "^2.6@dev",
"vluzrmos/tinker": "dev-master",
"moon/artisan": "dev-master"

I've seen similar problems here for example: http://ift.tt/1WQDYgq http://ift.tt/1ETVyVN

but never the answer was given directly and actually I do not understand how to solve this problem? I would need direct answer because I'm newbie in Laravel. Can artisan be updated somehow easy with Linux command line so it can work again?



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/1ETVxB9
via IFTTT

Aucun commentaire:

Enregistrer un commentaire