Uppy + Laravel无法上传文件

时间:2020-01-09 10:03:30

标签: laravel uppy

尝试使用Uppy JS库通过Laravel上传文件。设置带有参数的简单上传表单:

const options = {
    endpoint: '/parts/image-upload',
    headers: {
        'X-XSRF-TOKEN': $('meta[name="csrf-token"]').attr('content'),
    },
};

uppyDashboard.use(XHRUpload, options);

在后端,我得到

Illuminate\Contracts\Encryption\DecryptException: The payload is invalid. in file /Users/rd/Projects/xxx/vendor/laravel/framework/src/Illuminate/Encryption/Encrypter.php on line 195

就像Laravel试图解密已经解密的东西一样,无论如何我都处于死胡同。

0 个答案:

没有答案