mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-30 15:52:17 +09:00
Add helpful error messages to 3 most common error types
최근 커뮤니티 검색에서 가장 자주 발견되는 에러 타입 3가지: - 문자열에 따옴표 안 씀 - stdClass 정의 안 함 - 배열이 아닌 것에 배열 함수 사용
This commit is contained in:
parent
a36177d772
commit
76fdcea292
3 changed files with 9 additions and 0 deletions
|
|
@ -106,6 +106,9 @@ class MessageView extends Message
|
|||
{
|
||||
$regexp_list = [
|
||||
'/Class [\'"]Object[\'"] not found/' => 'baseobject',
|
||||
'/Undefined constant [\'"][^\'"]+?[\'"]/' => 'undef_constant',
|
||||
'/Attempt to assign property [\'"][^\'"]+?[\'"] on null/' => 'undef_object',
|
||||
'/Argument #\d+ \(\$\w+\) must be of type (Countable\|)?array, \w+ given ?/' => 'not_array',
|
||||
];
|
||||
|
||||
foreach ($regexp_list as $regexp => $key)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue