File "TwoFactorQrCodeController.php"
Full Path: /home/fundopuh/trader.fxex.org/vendor/laravel/fortify/src/Http/Controllers/TwoFactorQrCodeController.php
File size: 697 bytes
MIME-type: text/x-php
Charset: utf-8
<?php
namespace Laravel\Fortify\Http\Controllers;
use Illuminate\Http\Request;
use Illuminate\Routing\Controller;
class TwoFactorQrCodeController extends Controller
{
/**
* Get the SVG element for the user's two factor authentication QR code.
*
* @param \Illuminate\Http\Request $request
* @return \Symfony\Component\HttpFoundation\Response
*/
public function show(Request $request)
{
if (is_null($request->user()->two_factor_secret)) {
return [];
}
return response()->json([
'svg' => $request->user()->twoFactorQrCodeSvg(),
'url' => $request->user()->twoFactorQrCodeUrl(),
]);
}
}