mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-06-20 11:47:53 +02:00
Fix #9
This commit is contained in:
parent
04af792b58
commit
bf31a9b599
@ -44,7 +44,7 @@ class QrCodeController extends Controller
|
|||||||
public function decode(Request $request)
|
public function decode(Request $request)
|
||||||
{
|
{
|
||||||
|
|
||||||
if(Options::get('useBasicQrcodeReader')) {
|
if( Options::get('useBasicQrcodeReader') || $request->inputFormat === 'fileUpload') {
|
||||||
|
|
||||||
// input validation
|
// input validation
|
||||||
$this->validate($request, [
|
$this->validate($request, [
|
||||||
|
@ -215,6 +215,7 @@
|
|||||||
|
|
||||||
let imgdata = new FormData();
|
let imgdata = new FormData();
|
||||||
imgdata.append('qrcode', this.$refs.qrcodeInput.files[0]);
|
imgdata.append('qrcode', this.$refs.qrcodeInput.files[0]);
|
||||||
|
imgdata.append('inputFormat', 'fileUpload');
|
||||||
|
|
||||||
const { data } = await this.form.upload('/api/qrcode/decode', imgdata)
|
const { data } = await this.form.upload('/api/qrcode/decode', imgdata)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user