$params[0]]] : []; } return $GLOBALS['cdef_test_lists'][(int) ($params[0] ?? 0)] ?? []; } function db_fetch_cell_prepared(string $sql, array $params = [], string $col_name = '', bool $log = true, mixed $db_conn = false, float $timeout = 0) : mixed { $GLOBALS['cdef_test_queries'][] = [$sql, $params, $col_name, $log, $db_conn, $timeout]; if (is_callable($GLOBALS['cdef_test_cell_callback'])) { $result = ($GLOBALS['cdef_test_cell_callback'])($sql, $params); if ($result !== null) { return $result; } } return $GLOBALS['cdef_test_names'][(int) ($params[0] ?? 0)] ?? false; } function cacti_sizeof(mixed $value) : int { return is_array($value) ? count($value) : 0; } function cacti_log(mixed $message, bool $output = false, string $environ = 'CMDPHP', mixed $level = '') : bool { $GLOBALS['cdef_test_logs'][] = [$message, $output, $environ, $level]; return true; } require_once dirname(__DIR__, 2) . '/lib/cdef.php';