mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-09-01 08:15:57 +02:00
refactor: format rendering (#4229)
This commit is contained in:
parent
c849576c93
commit
6516e31c1b
12 changed files with 25 additions and 50 deletions
|
@ -4,7 +4,7 @@ class SfeedFormat extends FormatAbstract
|
|||
{
|
||||
const MIME_TYPE = 'text/plain';
|
||||
|
||||
public function stringify()
|
||||
public function render(): string
|
||||
{
|
||||
$text = '';
|
||||
foreach ($this->getItems() as $item) {
|
||||
|
@ -26,13 +26,6 @@ class SfeedFormat extends FormatAbstract
|
|||
);
|
||||
}
|
||||
|
||||
// Remove invalid non-UTF8 characters
|
||||
ini_set('mbstring.substitute_character', 'none');
|
||||
$text = mb_convert_encoding(
|
||||
$text,
|
||||
$this->getCharset(),
|
||||
'UTF-8'
|
||||
);
|
||||
return $text;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue