我想更新到较新的 Craft CMS 版本,我尝试在控制面板中执行此操作。最新的可用版本是
3.7.12
。单击 update all
后,出现以下错误:
致命错误:声明
craft\helpers\FileHelper::getExtensionByMimeType($mimeType): 字符串 必须兼容 yii\helpers\BaseFileHelper::getExtensionByMimeType($mimeType, $preferShort = false, $magicFile = null) 中 /var/www/html/vendor/craftcms/cms/src/helpers/FileHelper.php 上线 719
后来我使用终端成功更新到3.8.2版本。所有依赖项也会更新,并且
yiisoft/yii2
版本设置为 2.0.45
。然而问题依然存在。
我尝试过的解决方案是这里,但它没有解决我的问题。
在
composer install
中运行 /var/www/html
修复了问题