<p>I would recommend deleting the vendor folder and then running <code>composer install</code> this should ensure any cruft that didn't make it quite right through an update is replaced.</p>

CC BY-SA 4.0
2023-12-18T19:35:57.737Z
2023-12-18T19:35:57.737Z
cherrykoda
<p>I've installed the latest CraftCMS version via composer.
When I'm visiting the plugins settings page (/web/admin/settings/plugins), I get the following error message:
<a href="https://i.sstatic.net/JjxJN.png" rel="nofollow noreferrer">preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated</a></p>
<pre><code>Application Info
PHP version                 8.2.13
OS version                  Linux 5.15.74-1-pve
Database driver &amp; version   MariaDB 10.6.12
Image driver &amp; version      Imagick 3.7.0 (ImageMagick 6.9.11-60)
Craft edition &amp; version     Craft Solo 4.5.11.1
Yii version                 2.0.48.1
Twig version                v3.4.3
Guzzle version              7.8.0
</code></pre>
<p>I'm using PHP 8.2, but I see that passing a null parameter to preg_replace() was also deprecated in PHP8.1. PHP8.0 is EOL. So I'm not sure what to do here.</p>

CC BY-SA 4.0
2023-12-08T13:52:05.593Z
Your screenshot is showing a completely different error message than the one mentioned in your post?
MoritzLost
<php><error-message><craft4>
Error on plugin settings page: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated
# Error on plugin settings page: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated

(Asked by: username_0 on 2023-12-08)

I've installed the latest CraftCMS version via composer.
When I'm visiting the plugins settings page (/web/admin/settings/plugins), I get the following error message:
preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated
Application Info
PHP version                 8.2.13
OS version                  Linux 5.15.74-1-pve
Database driver & version   MariaDB 10.6.12
Image driver & version      Imagick 3.7.0 (ImageMagick 6.9.11-60)
Craft edition & version     Craft Solo 4.5.11.1
Yii version                 2.0.48.1
Twig version                v3.4.3
Guzzle version              7.8.0

I'm using PHP 8.2, but I see that passing a null parameter to preg_replace() was also deprecated in PHP8.1. PHP8.0 is EOL. So I'm not sure what to do here.

**Tags:** php, error-message, craft4
> **Comments:**
> **username_1**: Your screenshot is showing a completely different error message than the one mentioned in your post?  

---

## 1 answers

### Answer by username_2 on 2023-12-18. Score: 1

I would recommend deleting the vendor folder and then running `composer install` this should ensure any cruft that didn't make it quite right through an update is replaced.


---

