Completed
Push — master ( 5a5893...f6c5ff )
by Mahmoud
03:48
created

WebLogoutTask::run()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 6
rs 9.4285
cc 1
eloc 3
nc 1
nop 0
1
<?php
2
3
namespace App\Containers\Authentication\Tasks;
4
5
use Illuminate\Auth\AuthManager as Auth;
6
7
/**
8
 * Class WebLogoutTask.
9
 *
10
 * @author Mahmoud Zalt <[email protected]>
11
 */
12
class WebLogoutTask
13
{
14
15
    /**
16
     * @var  \Illuminate\Auth\AuthManager
17
     */
18
    private $auth;
19
20
    /**
21
     * WebAuthenticationTask constructor.
22
     *
23
     * @param \Illuminate\Auth\AuthManager $auth
24
     */
25
    public function __construct(Auth $auth)
26
    {
27
        $this->auth = $auth;
28
    }
29
30
    /**
31
     * @return  bool
32
     */
33
    public function run()
34
    {
35
        $this->auth->logout();
36
37
        return true;
38
    }
39
40
}
41