From 12ba6154f93a4ad2cc3984a8381f6512461a87df Mon Sep 17 00:00:00 2001 From: rmscoelho <50850007+rmscoelho@users.noreply.github.com> Date: Wed, 21 Jun 2023 10:15:36 +0100 Subject: [PATCH] [JornalNBridge] cache timeout fix (#3452) * [JornalNBridge] cache timeout fix * [JornalNBridge] cache timeout fix --- bridges/JornalNBridge.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bridges/JornalNBridge.php b/bridges/JornalNBridge.php index 9a4fba45..aff455b1 100644 --- a/bridges/JornalNBridge.php +++ b/bridges/JornalNBridge.php @@ -6,7 +6,7 @@ class JornalNBridge extends BridgeAbstract const URI = 'https://www.jornaln.pt/'; const DESCRIPTION = 'Returns news from the Portuguese local newspaper Jornal N'; const MAINTAINER = 'rmscoelho'; - const CACHE_TIMEOUT = 10; + const CACHE_TIMEOUT = 86400; const PARAMETERS = [ [ 'feed' => [ @@ -72,7 +72,7 @@ class JornalNBridge extends BridgeAbstract public function collectData() { $url = sprintf('https://www.jornaln.pt/%s', $this->getInput('feed')); - $dom = getSimpleHTMLDOM($url); + $dom = getSimpleHTMLDOMCached($url); $domSelector = '.elementor-widget-container > .elementor-posts-container'; $dom = $dom->find($domSelector, 0); if (!$dom) {