|
|
@ -285,9 +285,15 @@ $server->setHandler( |
|
|
|
// Value |
|
|
|
// Value |
|
|
|
$result[] = null; |
|
|
|
$result[] = null; |
|
|
|
$result[] = trim( |
|
|
|
$result[] = trim( |
|
|
|
preg_replace( // remove extra breaks |
|
|
|
preg_replace( |
|
|
|
'/[\n\r]{3,}/', |
|
|
|
[ |
|
|
|
PHP_EOL . PHP_EOL, |
|
|
|
'/(^|\s+)(#|\*|```|=>)/', // escape gemini text |
|
|
|
|
|
|
|
'/[\n\r]{3,}/', // remove extra breaks |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
[ |
|
|
|
|
|
|
|
'$1 $2', |
|
|
|
|
|
|
|
PHP_EOL . PHP_EOL, |
|
|
|
|
|
|
|
], |
|
|
|
$record['value'] |
|
|
|
$record['value'] |
|
|
|
) |
|
|
|
) |
|
|
|
); |
|
|
|
); |
|
|
@ -518,9 +524,15 @@ $server->setHandler( |
|
|
|
|
|
|
|
|
|
|
|
// Value |
|
|
|
// Value |
|
|
|
$result[] = trim( |
|
|
|
$result[] = trim( |
|
|
|
preg_replace( // remove extra breaks |
|
|
|
preg_replace( |
|
|
|
'/[\n\r]{3,}/', |
|
|
|
[ |
|
|
|
PHP_EOL . PHP_EOL, |
|
|
|
'/(^|\s+)(#|\*|```|=>)/', // escape gemini text |
|
|
|
|
|
|
|
'/[\n\r]{3,}/', // remove extra breaks |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
[ |
|
|
|
|
|
|
|
'$1 $2', |
|
|
|
|
|
|
|
PHP_EOL . PHP_EOL, |
|
|
|
|
|
|
|
], |
|
|
|
$record['value'] |
|
|
|
$record['value'] |
|
|
|
) |
|
|
|
) |
|
|
|
); |
|
|
|
); |
|
|
|