mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-04-05 00:59:35 +00:00
[KemonoBridge] attempt to fix malformed tag responses (#4209)
This commit is contained in:
parent
129b8a3a5a
commit
2e6e246759
@ -55,9 +55,10 @@ class KemonoBridge extends BridgeAbstract
|
|||||||
if (is_array($tags)) {
|
if (is_array($tags)) {
|
||||||
$item['categories'] = $tags;
|
$item['categories'] = $tags;
|
||||||
} else {
|
} else {
|
||||||
$tags = preg_replace('/^{"?/', '["', $tags);
|
$tags = preg_replace('/^{/', '', $tags);
|
||||||
$tags = preg_replace('/"?}$/', '"]', $tags);
|
$tags = preg_replace('/}$/', '', $tags);
|
||||||
$item['categories'] = Json::decode($tags);
|
$tags = preg_replace('/"/', '', $tags);
|
||||||
|
$item['categories'] = explode(',', $tags);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user