How to solve this problem? I alreay tried to use the whole solution from the network, and I also tried to use Illuminate \ Foundation \ Auth \ AuthenticatesAndRegistersUsers, but none of them work ?. If anyone knows how to solve this, please help me. I want to get rid of this error. thanks in advance
<?php namespace App\Http\Controllers\Auth; use Illuminate\Foundation\Auth\AuthenticatesAndRegistersUsers; use Illuminate\Support\Facades\Validator; use Illuminate\Support\Facades\Input; use Illuminate\Support\Facades\Redirect; use Illuminate\Routing\Controller as BaseController; use Theme; use Auth; use App\Login; use Illuminate\Foundation\Auth\ThrottlesLogins; use App\Http\Controllers\Auth\RegisterController; class LoginController extends BaseController { use AuthenticatesAndRegistersUsers, ThrottlesLogins; protected $redirectTo = '/'; public function __construct() { $this->middleware('guest', ['except' => 'logout']); } public function signin(){ if(Auth::check()){ return Redirect::to('/'); }else{ $theme = Theme::uses('default')->layout('default'); return $theme->of('login.sign-in')->render(); } } public function login(){ $data = array( 'email' => Input::get('email'), 'password' => Input::get('password') ); $validator= RegisterController::validator($data); if($validator){ return Redirect::to('/login')->withErrors([$validator->errors()->all() ]); }else{ return Redirect::to('/'); } }
source share