for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* fast-image-size base class
* @package fast-image-size
* @copyright (c) Marc Alexander <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace FastImageSize;
class FastImageSize
{
public function getImageSize($file, $type = '')
$type
If this is a false-positive, you can also ignore this issue in your code via the ignore-unused annotation
ignore-unused
public function getImageSize($file, /** @scrutinizer ignore-unused */ $type = '')
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.
$size = getimagesize($file);
if (empty($size)) {
return false;
}
return array(
'width' => $size[0],
'height' => $size[1],
'type' => $size[2],
);
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.