Completed
Push — master ( 0d663c...33e019 )
by vistart
03:45 queued 55s
created

DeleteUser   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 2
lcom 1
cbo 2
dl 0
loc 18
c 1
b 0
f 1
ccs 4
cts 4
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A init() 0 5 2
1
<?php
2
3
/**
4
 *  _   __ __ _____ _____ ___  ____  _____
5
 * | | / // // ___//_  _//   ||  __||_   _|
6
 * | |/ // /(__  )  / / / /| || |     | |
7
 * |___//_//____/  /_/ /_/ |_||_|     |_|
8
 * @link https://vistart.me/
9
 * @copyright Copyright (c) 2016 - 2017 vistart
10
 * @license https://vistart.me/license/
11
 */
12
13
namespace rhosocial\user\rbac\permissions;
14
15
use rhosocial\user\rbac\rules\DeleteUserRule;
16
use rhosocial\user\rbac\Permission;
17
18
/**
19
 * @version 1.0
20
 * @author vistart <[email protected]>
21
 */
22
class DeleteUser extends Permission
23
{
24
    /**
25
     * @inheritdoc
26
     */
27
    public $name = 'deleteUser';
28
    
29
    /**
30
     * @inheritdoc
31
     */
32
    public $description = 'Delete a user';
33
    
34 2
    public function init()
35
    {
36 2
        parent::init();
37 2
        $this->ruleName = empty($this->ruleName) ? (new DeleteUserRule())->name : $this->ruleName;
38 2
    }
39
}
40