LinkRecord::getKeyChain()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 6
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: dsmrt
5
 * Date: 2/9/18
6
 * Time: 2:10 PM
7
 */
8
namespace flipbox\saml\core\records;
9
10
use craft\db\ActiveRecord;
11
use yii\db\ActiveQuery;
12
use flipbox\keychain\records\KeyChainRecord;
13
14
class LinkRecord extends ActiveRecord
15
{
16
17
    use traits\Ember;
18
    const TABLE_ALIAS = 'saml_provider_keychain_link';
19
20
    /**
21
     * @return ActiveQuery
22
     */
23
    public function getKeyChain()
24
    {
25
        return $this->hasOne(KeyChainRecord::class, [
26
            'keyChainId' => 'uid',
27
        ]);
28
    }
29
}
30