You've already forked EasyImages2.0
mirror of
https://github.com/icret/EasyImages2.0.git
synced 2025-12-13 11:43:58 +08:00
修复webp转换其他格式失败
This commit is contained in:
@@ -39,7 +39,12 @@ if ($handle->uploaded) {
|
||||
// 最小高度
|
||||
$handle->image_min_height = $config['minHeight'];
|
||||
// 转换图片为指定格式
|
||||
$handle->image_convert = $config['imgConvert'];
|
||||
if (isset($config['imgConvert'])) {
|
||||
// 只转换非webp格式和非动态图片
|
||||
if ($handle->file_src_name_ext !== 'webp' && !isAnimatedGif($handle->file_src_pathname)) {
|
||||
$handle->image_convert = $config['imgConvert'];
|
||||
}
|
||||
}
|
||||
|
||||
// 存储图片路径:images/201807/
|
||||
$handle->process('../' . config_path());
|
||||
|
||||
Reference in New Issue
Block a user