Completed
Push — master ( 86d7d8...3dc8f7 )
by vistart
04:16
created

ManageProfileRule   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 18
rs 10
c 1
b 0
f 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A execute() 0 4 1
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\organization\rbac\rules;
14
15
use rhosocial\user\User;
16
use rhosocial\organization\rbac\permissions\ManageProfile;
17
use yii\rbac\Rule;
18
19
/**
20
 * @version 1.0
21
 * @author vistart <[email protected]>
22
 */
23
class ManageProfileRule extends Rule
24
{
25
    public $name = 'canManageProfile';
26
    
27
    /**
28
     * Executes the rule.
29
     *
30
     * @param string|User $user the user GUID. This should be either a GUID string representing
31
     * the unique identifier of a user or a User instance. See [[\rhosocial\user\User::guid]].
32
     * @param ManageProfile $item
33
     * @param array $params parameters passed to [[CheckAccessInterface::checkAccess()]].
34
     * @return bool a value indicating whether the rule permits the auth item it is associated with.
35
     */
36
    public function execute($user, $item, $params)
37
    {
38
        
39
    }
40
}
41