Test Failed
Pull Request — master (#115)
by Alex
03:29
created

AssociationStubMonomorphic::isCompatible()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 7
rs 9.4285
cc 2
eloc 4
nc 2
nop 1
1
<?php
2
3
namespace AlgoWeb\PODataLaravel\Models;
4
5
class AssociationStubMonomorphic extends AssociationStubBase
6
{
7
    public function isCompatible(AssociationStubBase $otherStub)
8
    {
9
        if (!parent::isCompatible($otherStub)) {
10
            return false;
11
        }
12
        return $this->getForeignField() === $otherStub->getKeyField();
13
    }
14
}
15