diff --git a/models/GenericTable.php b/models/GenericTable.php index 50cf258..2fcb900 100644 --- a/models/GenericTable.php +++ b/models/GenericTable.php @@ -217,31 +217,9 @@ class GenericTable private function processFormatting($options, $rowData) { - if (!isset($options['type'])) - $options['type'] = 'value'; - // Parse the basic value first. switch ($options['type']) { - // Basic option: simply take a use a particular data property. - case 'value': - $value = htmlspecialchars($rowData[$options['data']] ?? ''); - break; - - // Processing via a lambda function. - case 'function': - $value = $options['data']($rowData); - break; - - // Using sprintf to fill out a particular pattern. - case 'sprintf': - $parameters = [$options['data']['pattern']]; - foreach ($options['data']['arguments'] as $identifier) - $parameters[] = $rowData[$identifier]; - - $value = sprintf(...$parameters); - break; - // Timestamps get custom treatment. case 'timestamp': if (empty($options['data']['pattern']) || $options['data']['pattern'] === 'long')