Php Laravel社交名流请求返回Null

Php Laravel社交名流请求返回Null,php,laravel,laravel-5,laravel-socialite,laravel-request,Php,Laravel,Laravel 5,Laravel Socialite,Laravel Request,我用的是拉威尔社交名媛5.0 <?php use Illuminate\Http\Request; public function login(AuthenticateUser $authenticateUser, Request $request){ return $authenticateUser->execute($request->has('code')); } 正在添加AuthController类以供参考: class AuthController e

我用的是拉威尔社交名媛5.0

<?php

use Illuminate\Http\Request;

public function login(AuthenticateUser $authenticateUser, Request $request){
    return $authenticateUser->execute($request->has('code'));
}
正在添加AuthController类以供参考:

class AuthController extends Controller {

    /*
    |--------------------------------------------------------------------------
    | Registration & Login Controller
    |--------------------------------------------------------------------------
    |
    | This controller handles the registration of new users, as well as the
    | authentication of existing users. By default, this controller uses
    | a simple trait to add these behaviors. Why don't you explore it?
    |
    */

    use AuthenticatesAndRegistersUsers;

    /**
     * Create a new authentication controller instance.
     *
     * @param  \Illuminate\Contracts\Auth\Guard  $auth
     * @param  \Illuminate\Contracts\Auth\Registrar  $registrar
     * @return void
     */
    public function __construct(Guard $auth, Registrar $registrar)
    {
        $this->auth = $auth;
        $this->registrar = $registrar;

        $this->middleware('guest', ['except' => 'getLogout']);
    }

    public function login(AuthenticateUser $authenticateUser, Request $request){
        Log::info('_'.$request->has('code').'_');
        return $authenticateUser->execute($request->has('code'));
    }

}

问题在于返回url路由!
我从应用程序返回到错误的路径。

我遵循laracast教程:但无法通过此“代码”。触发函数的表单是什么样子的?它不是表单。我只是触发路线。您可以发布您的authenticate用户类吗?您是否在services.php文件中提供了正确的令牌?
class AuthController extends Controller {

    /*
    |--------------------------------------------------------------------------
    | Registration & Login Controller
    |--------------------------------------------------------------------------
    |
    | This controller handles the registration of new users, as well as the
    | authentication of existing users. By default, this controller uses
    | a simple trait to add these behaviors. Why don't you explore it?
    |
    */

    use AuthenticatesAndRegistersUsers;

    /**
     * Create a new authentication controller instance.
     *
     * @param  \Illuminate\Contracts\Auth\Guard  $auth
     * @param  \Illuminate\Contracts\Auth\Registrar  $registrar
     * @return void
     */
    public function __construct(Guard $auth, Registrar $registrar)
    {
        $this->auth = $auth;
        $this->registrar = $registrar;

        $this->middleware('guest', ['except' => 'getLogout']);
    }

    public function login(AuthenticateUser $authenticateUser, Request $request){
        Log::info('_'.$request->has('code').'_');
        return $authenticateUser->execute($request->has('code'));
    }

}