Skip to content

Commit

Permalink
Fix(php-cs-fixer) Fix php-cs-fixer warnings, according to new checks
Browse files Browse the repository at this point in the history
  • Loading branch information
thePanz committed Nov 17, 2023
1 parent e8d9c3c commit 4470e8a
Show file tree
Hide file tree
Showing 411 changed files with 402 additions and 1,842 deletions.
8 changes: 1 addition & 7 deletions data/bin/check_configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ function is_cli()

/**
* Checks a configuration.
*
* @param mixed $boolean
* @param mixed $message
* @param mixed $help
* @param mixed $fatal
*/
function check($boolean, $message, $help = '', $fatal = false)
{
Expand Down Expand Up @@ -84,8 +79,7 @@ function get_ini_path()
$accelerator =
(function_exists('apc_store') && ini_get('apc.enabled'))
|| function_exists('eaccelerator_put') && ini_get('eaccelerator.enable')
|| function_exists('xcache_set')
;
|| function_exists('xcache_set');
check($accelerator, 'A PHP accelerator is installed', 'Install a PHP accelerator like APC (highly recommended)', false);

check(!ini_get('short_open_tag'), 'php.ini has short_open_tag set to off', 'Set it to off in php.ini', false);
Expand Down
10 changes: 2 additions & 8 deletions lib/action/sfAction.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,14 @@ public function initialize($context, $moduleName, $actionName)
*
* By default, this method is empty.
*/
public function preExecute()
{
}
public function preExecute() {}

/**
* Execute an application defined process immediately after execution of this sfAction object.
*
* By default, this method is empty.
*/
public function postExecute()
{
}
public function postExecute() {}

/**
* Forwards current action to the default 404 error action.
Expand Down Expand Up @@ -385,8 +381,6 @@ public function setSecurityConfiguration($security)
*
* @param string $name The name of the value to pull from security.yml
* @param mixed $default The default value to return if none is found in security.yml
*
* @return mixed
*/
public function getSecurityValue($name, $default = null)
{
Expand Down
2 changes: 0 additions & 2 deletions lib/action/sfComponents.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@ abstract class sfComponents extends sfComponent
/**
* @param sfRequest $request
*
* @return mixed
*
* @throws sfInitializationException
*
* @see sfComponent
Expand Down
10 changes: 0 additions & 10 deletions lib/addon/sfPager.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,6 @@ public function setCursor($pos)
* Returns an object by cursor position.
*
* @param int $pos
*
* @return mixed
*/
public function getObjectByCursor($pos)
{
Expand All @@ -167,8 +165,6 @@ public function getObjectByCursor($pos)

/**
* Returns the current object.
*
* @return mixed
*/
public function getCurrent()
{
Expand Down Expand Up @@ -397,9 +393,6 @@ public function getParameterHolder()
* Returns a parameter.
*
* @param string $name
* @param mixed $default
*
* @return mixed
*/
public function getParameter($name, $default = null)
{
Expand All @@ -422,7 +415,6 @@ public function hasParameter($name)
* Sets a parameter.
*
* @param string $name
* @param mixed $value
*/
public function setParameter($name, $value)
{
Expand Down Expand Up @@ -525,8 +517,6 @@ public function count()
* Used internally by {@link getCurrent()}.
*
* @param int $offset
*
* @return mixed
*/
abstract protected function retrieveObject($offset);

Expand Down
4 changes: 1 addition & 3 deletions lib/autoload/sfAutoload.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,7 @@ class sfAutoload
protected $overriden = array();
protected $classes = array();

protected function __construct()
{
}
protected function __construct() {}

/**
* Retrieves the singleton instance of this class.
Expand Down
4 changes: 1 addition & 3 deletions lib/autoload/sfAutoloadAgain.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@ class sfAutoloadAgain
/**
* Constructor.
*/
protected function __construct()
{
}
protected function __construct() {}

/**
* Returns the singleton autoloader.
Expand Down
9 changes: 0 additions & 9 deletions lib/cache/sfAPCCache.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ class sfAPCCache extends sfCache
* * see sfCache for options available for all drivers
*
* @see sfCache
* {@inheritdoc}
*/
public function initialize($options = array())
{
Expand All @@ -38,7 +37,6 @@ public function initialize($options = array())

/**
* @see sfCache
* {@inheritdoc}
*/
public function get($key, $default = null)
{
Expand All @@ -53,7 +51,6 @@ public function get($key, $default = null)

/**
* @see sfCache
* {@inheritdoc}
*/
public function has($key)
{
Expand All @@ -68,7 +65,6 @@ public function has($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function set($key, $data, $lifetime = null)
{
Expand All @@ -81,7 +77,6 @@ public function set($key, $data, $lifetime = null)

/**
* @see sfCache
* {@inheritdoc}
*/
public function remove($key)
{
Expand All @@ -94,7 +89,6 @@ public function remove($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function clean($mode = sfCache::ALL)
{
Expand All @@ -109,7 +103,6 @@ public function clean($mode = sfCache::ALL)

/**
* @see sfCache
* {@inheritdoc}
*/
public function getLastModified($key)
{
Expand All @@ -122,7 +115,6 @@ public function getLastModified($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function getTimeout($key)
{
Expand All @@ -135,7 +127,6 @@ public function getTimeout($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function removePattern($pattern)
{
Expand Down
2 changes: 0 additions & 2 deletions lib/cache/sfCache.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -201,8 +201,6 @@ public function getOption($name, $default = null)
*
* @param string $name The option name
* @param mixed $value The option value
*
* @return mixed
*/
public function setOption($name, $value)
{
Expand Down
6 changes: 0 additions & 6 deletions lib/cache/sfEAcceleratorCache.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ public function initialize($options = array())
* @see sfCache
*
* @param string $key
* @param mixed $default
*
* @return string|null
*/
Expand Down Expand Up @@ -82,7 +81,6 @@ public function set($key, $data, $lifetime = null)

/**
* @see sfCache
* {@inheritdoc}
*/
public function remove($key)
{
Expand All @@ -91,7 +89,6 @@ public function remove($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function removePattern($pattern)
{
Expand All @@ -110,7 +107,6 @@ public function removePattern($pattern)

/**
* @see sfCache
* {@inheritdoc}
*/
public function clean($mode = sfCache::ALL)
{
Expand All @@ -136,7 +132,6 @@ public function clean($mode = sfCache::ALL)

/**
* @see sfCache
* {@inheritdoc}
*/
public function getLastModified($key)
{
Expand All @@ -149,7 +144,6 @@ public function getLastModified($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function getTimeout($key)
{
Expand Down
9 changes: 0 additions & 9 deletions lib/cache/sfFileCache.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ class sfFileCache extends sfCache
* * see sfCache for options available for all drivers
*
* @see sfCache
* {@inheritdoc}
*/
public function initialize($options = array())
{
Expand All @@ -48,7 +47,6 @@ public function initialize($options = array())

/**
* @see sfCache
* {@inheritdoc}
*/
public function get($key, $default = null)
{
Expand All @@ -68,7 +66,6 @@ public function get($key, $default = null)

/**
* @see sfCache
* {@inheritdoc}
*/
public function has($key)
{
Expand All @@ -79,7 +76,6 @@ public function has($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function set($key, $data, $lifetime = null)
{
Expand All @@ -92,7 +88,6 @@ public function set($key, $data, $lifetime = null)

/**
* @see sfCache
* {@inheritdoc}
*/
public function remove($key)
{
Expand All @@ -101,7 +96,6 @@ public function remove($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function removePattern($pattern)
{
Expand Down Expand Up @@ -130,7 +124,6 @@ public function removePattern($pattern)

/**
* @see sfCache
* {@inheritdoc}
*/
public function clean($mode = sfCache::ALL)
{
Expand All @@ -150,7 +143,6 @@ public function clean($mode = sfCache::ALL)

/**
* @see sfCache
* {@inheritdoc}
*/
public function getTimeout($key)
{
Expand All @@ -167,7 +159,6 @@ public function getTimeout($key)

/**
* @see sfCache
* {@inheritdoc}
*/
public function getLastModified($key)
{
Expand Down
Loading

0 comments on commit 4470e8a

Please sign in to comment.