mirror of https://gitee.com/karson/fastadmin.git
优化上传异常捕获
parent
7fffba8963
commit
31b307a4a1
|
|
@ -137,6 +137,8 @@ class Common extends Api
|
||||||
$attachment = $upload->upload();
|
$attachment = $upload->upload();
|
||||||
} catch (UploadException $e) {
|
} catch (UploadException $e) {
|
||||||
$this->error($e->getMessage());
|
$this->error($e->getMessage());
|
||||||
|
} catch (\Exception $e) {
|
||||||
|
$this->error($e->getMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->success(__('Uploaded successful'), ['url' => $attachment->url, 'fullurl' => cdnurl($attachment->url, true)]);
|
$this->success(__('Uploaded successful'), ['url' => $attachment->url, 'fullurl' => cdnurl($attachment->url, true)]);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue