Passed
Push — master ( e47858...55d38d )
by Carsten
02:40
created

Exposures::search()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 1
1
<?php
2
namespace FilmTools\Commons;
3
4
5
class Exposures extends MinMaxArrayIterator implements ExposuresInterface, ExposuresProviderInterface
6
{
7
    /**
8
     * @inheritDoc
9
     * @return $this
10
     */
11 9
    public function getExposures() : ExposuresInterface
12
    {
13 9
        return $this;
14
    }
15
16
    /**
17
     * @inheritDoc
18
     */
19 9
    public function search( float $logH )
20
    {
21 9
        return array_search($logH, $this->getArrayCopy());
0 ignored issues
show
Bug Compatibility introduced by
The expression array_search($logH, $this->getArrayCopy()); of type false|integer|string adds the type string to the return on line 21 which is incompatible with the return type declared by the interface FilmTools\Commons\SearchableInterface::search of type integer|false.
Loading history...
22
    }
23
24
}
25