Merge remote-tracking branch 'origin/master' into akun
正在显示
1 个修改的文件
包含
6 行增加
和
6 行删除
| @@ -380,23 +380,23 @@ class ImageController extends Controller | @@ -380,23 +380,23 @@ class ImageController extends Controller | ||
| 380 | if(is_array($files)){ | 380 | if(is_array($files)){ |
| 381 | foreach ($files as $file){ | 381 | foreach ($files as $file){ |
| 382 | if(isset($this->cache['image_max']) && ($this->cache['image_max'] != 0)){ | 382 | if(isset($this->cache['image_max']) && ($this->cache['image_max'] != 0)){ |
| 383 | - if ($file->getSize() > $this->cache['image_max']) { | ||
| 384 | - $this->response('图片最大为500K',Code::SYSTEM_ERROR); | 383 | + if ($file->getSize() > $this->cache['image_max'] * 1024) { |
| 384 | + $this->response('图片最大为1024K',Code::SYSTEM_ERROR); | ||
| 385 | } | 385 | } |
| 386 | }else{ | 386 | }else{ |
| 387 | if ($file->getSize() > $max) { | 387 | if ($file->getSize() > $max) { |
| 388 | - $this->response('图片最大为500K',Code::SYSTEM_ERROR); | 388 | + $this->response('图片最大为1024K',Code::SYSTEM_ERROR); |
| 389 | } | 389 | } |
| 390 | } | 390 | } |
| 391 | } | 391 | } |
| 392 | }else{ | 392 | }else{ |
| 393 | if(isset($this->cache['image_max']) && ($this->cache['image_max'] != 0)){ | 393 | if(isset($this->cache['image_max']) && ($this->cache['image_max'] != 0)){ |
| 394 | - if ($files->getSize() > $this->cache['image_max']) { | ||
| 395 | - $this->response('图片最大为500K',Code::SYSTEM_ERROR); | 394 | + if ($files->getSize() > $this->cache['image_max'] * 1024) { |
| 395 | + $this->response('图片最大为1024K',Code::SYSTEM_ERROR); | ||
| 396 | } | 396 | } |
| 397 | }else{ | 397 | }else{ |
| 398 | if ($files->getSize() > $max) { | 398 | if ($files->getSize() > $max) { |
| 399 | - $this->response('图片最大为500K',Code::SYSTEM_ERROR); | 399 | + $this->response('图片最大为1024K',Code::SYSTEM_ERROR); |
| 400 | } | 400 | } |
| 401 | } | 401 | } |
| 402 | } | 402 | } |
-
请 注册 或 登录 后发表评论