StreamToFileFilter   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 4
c 1
b 0
f 1
dl 0
loc 12
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A streamFilter() 0 5 1
1
<?php
2
3
/**
4
 * This file is part of the PHP-FFmpeg-video-streaming package.
5
 *
6
 * (c) Amin Yazdanpanah <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
13
namespace Streaming\Filters;
14
15
16
use Streaming\StreamInterface;
17
18
class StreamToFileFilter extends FormatFilter
19
{
20
21
    /**
22
     * @param $media
23
     * @return mixed
24
     */
25
    public function streamFilter(StreamInterface $media): void
26
    {
27
        $this->filter = array_merge(
28
            $this->getFormatOptions($media->getFormat()),
29
            $media->getParams()
0 ignored issues
show
Bug introduced by
The method getParams() does not exist on Streaming\StreamInterface. It seems like you code against a sub-type of Streaming\StreamInterface such as Streaming\StreamToFile. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

29
            $media->/** @scrutinizer ignore-call */ 
30
                    getParams()
Loading history...
30
        );
31
    }
32
}