mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-17 23:13:15 +00:00
Fix coding standards
This commit is contained in:
@@ -91,7 +91,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
}
|
||||
catch (Exception $e)
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
$sql = 'SELECT id, title, subtitle, created_on, updated_on, base_id, public
|
||||
@@ -135,6 +135,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
public function get_icon_url()
|
||||
{
|
||||
if ($this->icon_url)
|
||||
|
||||
return $this->icon_url;
|
||||
|
||||
$url = '/skins/icons/rss32.gif';
|
||||
@@ -248,6 +249,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
public function has_access(User_Adapter $user)
|
||||
{
|
||||
if ($this->get_collection() instanceof collection)
|
||||
|
||||
return $user->ACL()->has_access_to_base($this->collection->get_base_id());
|
||||
return true;
|
||||
}
|
||||
@@ -262,7 +264,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
return $this->public;
|
||||
}
|
||||
|
||||
@@ -292,6 +294,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
public function add_publisher(User_Adapter $user)
|
||||
{
|
||||
if (in_array($user->get_id(), array_keys($this->get_publishers())))
|
||||
|
||||
return $this;
|
||||
|
||||
Feed_Publisher_Adapter::create($this->appbox, $user, $this, false);
|
||||
@@ -307,6 +310,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
protected function load_publishers()
|
||||
{
|
||||
if (is_array($this->publishers))
|
||||
|
||||
return $this->publishers;
|
||||
|
||||
$sql = 'SELECT id, usr_id, owner FROM feed_publishers
|
||||
@@ -493,7 +497,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
}
|
||||
catch (Exception $e)
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
$sql = 'SELECT count(id) as number
|
||||
@@ -596,6 +600,7 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
public function get_homepage_link(registryInterface $registry, $format, $page = null)
|
||||
{
|
||||
if (!$this->is_public())
|
||||
|
||||
return null;
|
||||
switch ($format)
|
||||
{
|
||||
@@ -637,11 +642,12 @@ class Feed_Adapter extends Feed_Abstract implements Feed_Interface, cache_cachea
|
||||
try
|
||||
{
|
||||
if (!$renew)
|
||||
|
||||
return $this->get_data_from_cache($cache_key);
|
||||
}
|
||||
catch (Exception $e)
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
$sql = 'SELECT token FROM feed_tokens
|
||||
|
Reference in New Issue
Block a user