diff options
Diffstat (limited to 'Zotlabs/Lib/Config.php')
| -rw-r--r-- | Zotlabs/Lib/Config.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Zotlabs/Lib/Config.php b/Zotlabs/Lib/Config.php index cd8b08991..139affa09 100644 --- a/Zotlabs/Lib/Config.php +++ b/Zotlabs/Lib/Config.php @@ -132,8 +132,8 @@ class Config { $value = App::$config[$family][$key]; if (! is_array($value)) { - if (substr($value, 0, 5) == 'json:') { - return json_decode(substr($value, 5), true); + if (str_starts_with($value, 'json:')) { + return unserialise($value); } else if (preg_match('|^a:[0-9]+:{.*}$|s', $value)) { // Unserialize in inherently unsafe. Try to mitigate by not // allowing unserializing objects. Only kept for backwards |
