mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-08-14 04:24:05 +02:00
fix: various bug fixes (#3102)
* fix: Undefined offset: 4 * fix: Trying to access array offset on value of type bool * fix: Undefined variable: photo at bridges/TelegramBridge.php line 287 * fix: Trying to get property innertext of non-object at bridges/ZDNetBridge.php line 186 * fix: Undefined index: Category at bridges/UnraidCommunityApplicationsBridge.php line 42 * fix: Undefined index: fullUrl at bridges/EuronewsBridge.php line 61
This commit is contained in:
@@ -91,11 +91,14 @@ class PornhubBridge extends BridgeAbstract
|
||||
$item['content'] = '<a href="' . $item['uri'] . '"><img src="' . $image . '"></a>';
|
||||
}
|
||||
|
||||
// date hack, guess upload YYYYMMDD from thumbnail URL (format: https://ci.phncdn.com/videos/201907/25/--- )
|
||||
$uploaded = explode('/', $image);
|
||||
$uploaded = strtotime($uploaded[4] . $uploaded[5]);
|
||||
$item['timestamp'] = $uploaded;
|
||||
|
||||
if (isset($uploaded[4])) {
|
||||
// date hack, guess upload YYYYMMDD from thumbnail URL (format: https://ci.phncdn.com/videos/201907/25/--- )
|
||||
$uploadTimestamp = strtotime($uploaded[4] . $uploaded[5]);
|
||||
$item['timestamp'] = $uploadTimestamp;
|
||||
} else {
|
||||
// The thumbnail url did not have a date in it for some unknown reason
|
||||
}
|
||||
$this->items[] = $item;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user