mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-15 05:53:13 +00:00
PHPCS fixing and avoid returns in some constructors
This commit is contained in:
@@ -67,10 +67,9 @@ class media_Permalink_Adapter implements media_Permalink_Interface, cache_cachea
|
||||
protected $app;
|
||||
|
||||
/**
|
||||
*
|
||||
* @param databox $databox
|
||||
* @param media_subdef $media_subdef
|
||||
* @return media_Permalink_Adapter
|
||||
* @param Application $app
|
||||
* @param databox $databox
|
||||
* @param media_subdef $media_subdef
|
||||
*/
|
||||
protected function __construct(Application $app, databox $databox, media_subdef $media_subdef)
|
||||
{
|
||||
@@ -79,8 +78,6 @@ class media_Permalink_Adapter implements media_Permalink_Interface, cache_cachea
|
||||
$this->media_subdef = $media_subdef;
|
||||
|
||||
$this->load();
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -297,7 +294,6 @@ class media_Permalink_Adapter implements media_Permalink_Interface, cache_cachea
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param Application $app
|
||||
* @param databox $databox
|
||||
* @param media_subdef $media_subdef
|
||||
|
@@ -138,9 +138,8 @@ class media_subdef extends media_abstract implements cache_cacheableInterface
|
||||
/**
|
||||
* @param Application $app
|
||||
* @param record_adapter $record
|
||||
* @param type $name
|
||||
* @param type $substitute
|
||||
* @return media_subdef
|
||||
* @param string $name
|
||||
* @param bool $substitute
|
||||
*/
|
||||
public function __construct(Application $app, record_adapter $record, $name, $substitute = false)
|
||||
{
|
||||
@@ -150,8 +149,6 @@ class media_subdef extends media_abstract implements cache_cacheableInterface
|
||||
$this->load($substitute);
|
||||
|
||||
$this->generate_url();
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -35,113 +35,32 @@ use Alchemy\Phrasea\Core\PhraseaTokens;
|
||||
|
||||
class record_adapter implements RecordInterface, cache_cacheableInterface
|
||||
{
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $xml;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $base_id;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $record_id;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $mime;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $number;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $status;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $subdefs;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $type;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $sha256;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $grouping;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var <type>
|
||||
*/
|
||||
protected $duration;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var databox
|
||||
*/
|
||||
/** @var databox */
|
||||
protected $databox;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var DateTime
|
||||
*/
|
||||
/** @var DateTime */
|
||||
protected $creation_date;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
/** @var string */
|
||||
protected $original_name;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var Array
|
||||
*/
|
||||
/** @var array */
|
||||
protected $technical_datas;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var caption_record
|
||||
*/
|
||||
/** @var caption_record */
|
||||
protected $caption_record;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
/** @var string */
|
||||
protected $uuid;
|
||||
|
||||
/**
|
||||
*
|
||||
* @var DateTime
|
||||
*/
|
||||
/** @var DateTime */
|
||||
protected $modification_date;
|
||||
/** @var Application */
|
||||
protected $app;
|
||||
|
||||
const CACHE_ORIGINAL_NAME = 'originalname';
|
||||
@@ -154,13 +73,10 @@ class record_adapter implements RecordInterface, cache_cacheableInterface
|
||||
const CACHE_STATUS = 'status';
|
||||
|
||||
/**
|
||||
*
|
||||
* @param Application $app
|
||||
* @param integer $sbas_id
|
||||
* @param integer $record_id
|
||||
* @param integer $number
|
||||
*
|
||||
* @return record_adapter
|
||||
*/
|
||||
public function __construct(Application $app, $sbas_id, $record_id, $number = null)
|
||||
{
|
||||
@@ -169,7 +85,7 @@ class record_adapter implements RecordInterface, cache_cacheableInterface
|
||||
$this->number = (int) $number;
|
||||
$this->record_id = (int) $record_id;
|
||||
|
||||
return $this->load();
|
||||
$this->load();
|
||||
}
|
||||
|
||||
protected function load()
|
||||
|
Reference in New Issue
Block a user