php7.4에서 에디터 설정을 불러오지 못하는 문제 수정

getModulePartConfig()는 호환(배열로 접근할 있도록)을 위해 ArrayObject::ARRAY_AS_PROPS 플래그가 설정된 ArrayObject를 반환하고 있는 데 php7.4의 get_object_vars() 함수는 이런 경우를 처리하지 못하는 것으로 확인됨 (빈 배열만 반환)

이 문제에 대해 php측에 제보했으나, 버그가 아니라는 답변을 받은 상태.
https://bugs.php.net/bug.php?id=79101
This commit is contained in:
conory 2020-01-16 21:43:08 +09:00
parent 6864746682
commit 56aca19fd2

View file

@ -276,7 +276,7 @@ class editorModel extends editor
// Convert configuration keys according to type (document or comment).
if($type == 'document')
{
foreach (get_object_vars($editor_config) as $key => $val)
foreach ((array)$editor_config as $key => $val)
{
$option->$key = $val;
}
@ -290,7 +290,7 @@ class editorModel extends editor
}
else
{
foreach (get_object_vars($editor_config) as $key => $val)
foreach ((array)$editor_config as $key => $val)
{
$option->$key = $val;
}