[InstagramBridge] Fix incorrect cache timeout calculation (#2840)

It is expected that getCacheTimeout returns integer. In fact
it returned boolean value which lead to situation, where Instagram feeds
were not cached.
This commit is contained in:
Eugene Molotov 2022-06-18 06:02:31 +05:00 committed by GitHub
parent c6ba3e5280
commit d0bea1627e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -70,7 +70,10 @@ class InstagramBridge extends BridgeAbstract {
public function getCacheTimeout() {
$customTimeout = $this->getOption('cache_timeout');
return $customTimeout || parent::getCacheTimeout();
if ($customTimeout) {
return $customTimeout;
}
return parent::getCacheTimeout();
}
protected function getContents($uri) {