Laravel

Solved: Call to undefined method Laravel\Lumen\Application::group()

You might have come across this issue while setting up LumenPassport

When you are listing routes via php artisan route:list

Error:

Error: Call to undefined method Laravel\Lumen\Application::group()

Solution

In your AppServiceProvider boot replace 

\Dusterio\LumenPassport\LumenPassport::routes($this->app);
by
Dusterio\LumenPassport\LumenPassport::routes($this->app->router) 

It's also depends, in which service provider did you place this in your app.

This will fix the problem.


Author: Danyal
I'm a skilled programmer specializing in Vue.js/Nuxt.js for front-end development and PHP Laravel for back-end solutions. I have a strong focus on API design and development, complemented by experience in web server setup and maintenance. My versatile expertise ensures seamless creation and maintenance of web applications, covering everything from intuitive user interfaces to robust server-side functionality. Passionate about coding and driven by a lifelong learning mindset, I invite you to explore more at danyal.dk.