public function getSignup($code = null)
    {
        if ($code === null) {
            throw new NotFoundHttpException();
        }

        $invite = Invite::where('code', '=', $code)->first();

        if (!$invite || $invite->is_claimed) {
            throw new BadRequestHttpException();
        }

        return View::make('signup')
            ->withCode($invite->code)
            ->withUsername(Binput::old('username'))
            ->withEmail(Binput::old('email', $invite->email));
    }
public function getSignup($code = null)
    {
        if ($code === null) {
            throw new NotFoundHttpException();
        }

        $invite = Invite::where('code', '=', $code)->first();

        if (!$invite || $invite->is_claimed) {
            throw new BadRequestHttpException();
        }

        return View::make('signup')
            ->withCode($invite->code)
            ->withUsername(Binput::old('username'))
            ->withEmail(Binput::old('email', $invite->email));
    }
public function getSignup ( $ code = null ) { if ( $ code === null ) { throw new NotFoundHttpException ( ) ; } $ invite = Invite :: where ( 'code' , '=' , $ code ) -> first ( ) ; if ( ! $ invite || $ invite -> is_claimed ) { throw new BadRequestHttpException ( ) ; } return View :: make ( 'signup' ) -> withCode ( $ invite -> code ) -> withUsername ( Binput :: old ( 'username' ) ) -> withEmail ( Binput :: old ( 'email' , $ invite -> email ) ) ; }
Handle the signup with invite.

@param string|null $code

@return \Illuminate\View\View
Handle the signup with invite .