Hi guys, when using the latest Laravel 5.2.2 and Entrust ("zizaco / entrust": "5.2.x-dev") I encounter this error and donβt know how to solve this problem.
Call to undefined method Zizaco\Entrust\EntrustServiceProvider::hasRole()
I checked this code on HomeController.php
use Entrust; class HomeController extends Controller { public function index() { if (Entrust::hasRole('admin')) { echo "string"; } return view('home'); } }
This is my config / app.php service provider
Zizaco\Entrust\EntrustServiceProvider::class
config / app.php alias
'Entrust' => Zizaco\Entrust\EntrustFacade::class
I also already created the required model



Did I miss something? thanks in advance
source share