Improve error log deduplication and occurrence tracking

Enhanced error deduplication by matching on type, file, line, and message. Updated error occurrence counting and admin stats to reflect deduplicated errors. Refactored error resolution and deletion to operate on all matching errors. Improved error occurrence display in the admin detail view for clarity and accuracy.
This commit is contained in:
Hosteroid
2026-01-08 14:19:09 +02:00
parent 24d5479dcf
commit 686f6f7528
3 changed files with 143 additions and 51 deletions

View File

@@ -229,9 +229,20 @@ class DebugController extends Controller
if (isset($entity['vcardArray'][1])) {
foreach ($entity['vcardArray'][1] as $field) {
if (is_array($field) && count($field) >= 4) {
// Handle nested arrays by flattening them recursively
$value = $field[3];
if (is_array($value)) {
$flattened = [];
array_walk_recursive($value, function($item) use (&$flattened) {
if (!is_array($item)) {
$flattened[] = $item;
}
});
$value = !empty($flattened) ? implode(', ', $flattened) : json_encode($value);
}
$parsedData[] = [
'key' => $field[0],
'value' => is_array($field[3]) ? implode(', ', $field[3]) : $field[3]
'value' => $value
];
}
}