Bahjaat

Bahjaat

Developer at KonnectIT

Member Since 5 Years Ago

Rotterdam

Experience Points
83,370
Total
Experience

1,630 experience to go until the next level!

In case you were wondering, you earn Laracasts experience when you:

  • Complete a lesson — 100pts
  • Create a forum thread — 50pts
  • Reply to a thread — 10pts
  • Leave a reply that is liked — 50pts
  • Receive a "Best Reply" award — 500pts
Lessons Completed
921
Lessons
Completed
Best Reply Awards
2
Best Reply
Awards
  • start your engines Created with Sketch.

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • first-thousand Created with Sketch.

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • 1-year Created with Sketch.

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • 2-years Created with Sketch.

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • 3-years Created with Sketch.

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • 4-years Created with Sketch.

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • 5-years Created with Sketch.

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • school-in-session Created with Sketch.

    School In Session

    Earned when at least one Laracasts series has been fully completed.

  • welcome-newcomer Created with Sketch.

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • full-time-student Created with Sketch.

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • pay-it-forward Created with Sketch.

    Pay It Forward

    Earned once you receive your first "Best Reply" award on the Laracasts forum.

  • subscriber Created with Sketch.

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • lifer Created with Sketch.

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • evangelist Created with Sketch.

    Laracasts Evangelist

    Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.

  • chatty-cathy Created with Sketch.

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • lara-veteran Created with Sketch.

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • 10k-strong Created with Sketch.

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • lara-master Created with Sketch.

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • laracasts-tutor Created with Sketch.

    Laracasts Tutor

    Earned once your "Best Reply" award count is 100 or more.

  • laracasts-sensei Created with Sketch.

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • top-50 Created with Sketch.

    Top 50

    Earned once your experience points ranks in the top 50 of all Laracasts users.

Level 17
83,370 XP
Oct
01
3 weeks ago
Activity icon

Replied to Revolve Artisan Command From Scheduler

I want to call a monitoring method on the Artisan Command where I can check whether or not the Command did what it had to do (and report to a monitoring system).

Sep
30
3 weeks ago
Activity icon

Replied to Php Artisan Tinker Throws Parse Error (unexpected T_PAAMAYIM_NEKUDOTAYIM)

composer update seems to fixed it (after a couple of days)

Activity icon

Started a new Conversation Revolve Artisan Command From Scheduler

I want to get the underlying Command when a cron (scheduled task) is running, or in my case had run. I'm hooking in the Event named ScheduledTaskFinished.

Is there a simpler way than doing this?

// EventListener

/**
     * Handle the event.
     *
     * @param ScheduledTaskFinished $event
     * @return void
     */
    public function handle(ScheduledTaskFinished $event)
    {
        $cliCommand = $event->task->command;

        $command = $this->getArtisanCommand($cliCommand);

        // ...
    }

    protected function getArtisanCommand($cliCommand)
    {
        $allArtisanCommands = \Artisan::all();
        return collect($allArtisanCommands)
            ->filter(function ($commandClass) use ($cliCommand) {
                $command = "'artisan' {$commandClass->getName()}";

                return \Str::contains($cliCommand, $command);
            })
            ->first();
    }
Sep
24
4 weeks ago
Activity icon

Replied to Php Artisan Tinker Throws Parse Error (unexpected T_PAAMAYIM_NEKUDOTAYIM)

Found out tinker can also have -vvv argument. php artisan tinker -vvv

Psy Shell v0.10.4 (PHP 7.3.22 — cli) by Justin Hileman
>>> \URL::to('test')
PHP Parse error: Syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM, expecting '(' on line 1
--
 () at vendor/psy/psysh/src/Exception/ParseErrorException.php:40
 Psy\Exception\ParseErrorException::fromParseError() at vendor/psy/psysh/src/CodeCleaner.php:294
 Psy\CodeCleaner->parse() at vendor/psy/psysh/src/CodeCleaner.php:221
 Psy\CodeCleaner->clean() at vendor/psy/psysh/src/Shell.php:829
 Psy\Shell->addCode() at vendor/psy/psysh/src/Shell.php:521
 Psy\Shell->getInput() at vendor/psy/psysh/src/ExecutionLoopClosure.php:40
 Psy\{closure}() at vendor/psy/psysh/src/ExecutionClosure.php:96
 Psy\ExecutionClosure->execute() at vendor/psy/psysh/src/Shell.php:370
 Psy\Shell->doInteractiveRun() at vendor/psy/psysh/src/Shell.php:341
 Psy\Shell->doRun() at vendor/symfony/console/Application.php:140
 Symfony\Component\Console\Application->run() at vendor/psy/psysh/src/Shell.php:316
 Psy\Shell->run() at vendor/laravel/tinker/src/Console/TinkerCommand.php:81
 Laravel\Tinker\Console\TinkerCommand->handle() at n/a:n/a
 call_user_func_array() at vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:37
 Illuminate\Container\BoundMethod::Illuminate\Container\{closure}() at vendor/laravel/framework/src/Illuminate/Container/Util.php:37
 Illuminate\Container\Util::unwrapIfClosure() at vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:95
 Illuminate\Container\BoundMethod::callBoundMethod() at vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:39
 Illuminate\Container\BoundMethod::call() at vendor/laravel/framework/src/Illuminate/Container/Container.php:596
 Illuminate\Container\Container->call() at vendor/laravel/framework/src/Illuminate/Console/Command.php:134
 Illuminate\Console\Command->execute() at vendor/symfony/console/Command/Command.php:258
 Symfony\Component\Console\Command\Command->run() at vendor/laravel/framework/src/Illuminate/Console/Command.php:121
 Illuminate\Console\Command->run() at vendor/symfony/console/Application.php:916
 Symfony\Component\Console\Application->doRunCommand() at vendor/symfony/console/Application.php:264
 Symfony\Component\Console\Application->doRun() at vendor/symfony/console/Application.php:140
 Symfony\Component\Console\Application->run() at vendor/laravel/framework/src/Illuminate/Console/Application.php:93
 Illuminate\Console\Application->run() at vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php:129
 Illuminate\Foundation\Console\Kernel->handle() at artisan:37

Package is still in my composer.json

Activity icon

Replied to Php Artisan Tinker Throws Parse Error (unexpected T_PAAMAYIM_NEKUDOTAYIM)

I'm a bit further. When I remove "darkaonline/l5-swagger": "^7.0" from composer.json tinker is working again. Added the package to the 'don't discover' part of the composer.json. Didn't mather.

How can I debug what tinker is doing/loading?

Activity icon

Replied to Php Artisan Tinker Throws Parse Error (unexpected T_PAAMAYIM_NEKUDOTAYIM)

No errors in application. Weird isn’t it?

Activity icon

Started a new Conversation Php Artisan Tinker Throws Parse Error (unexpected T_PAAMAYIM_NEKUDOTAYIM)

Somewhere lost today. Already cleared the vendor folder and updated packages one after another. Also removed a couple of packages. Nothing helped.

How to debug this?

php artisan tinker

>>> \URL::to('test');
PHP Parse error: Syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM, expecting '(' on line 1

>>> \App\User::first();
PHP Parse error: Syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM, expecting '(' on line 1