Completed
Push — master ( 52970f...c6d773 )
by Tristan
24:57 queued 10:40
created

WhichPortal   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 9
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
eloc 4
dl 0
loc 9
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A isManagerPortal() 0 3 1
A isApplicantPortal() 0 2 1
1
<?php
2
0 ignored issues
show
Coding Style introduced by
Missing file doc comment
Loading history...
3
namespace App\Services;
4
5
use Illuminate\Support\Facades\Route;
6
7
class WhichPortal {
0 ignored issues
show
Coding Style introduced by
Opening brace of a class must be on the line after the definition
Loading history...
Coding Style introduced by
Missing doc comment for class WhichPortal
Loading history...
8
9 28
    public function isApplicantPortal() {
0 ignored issues
show
Coding Style introduced by
Missing doc comment for function isApplicantPortal()
Loading history...
10 28
        return !$this->isManagerPortal();
11
    }
12
13 34
    public function isManagerPortal() {
0 ignored issues
show
Coding Style introduced by
Missing doc comment for function isManagerPortal()
Loading history...
14 34
        $routeName = Route::currentRouteName();
15 34
        return str_is('manager.*',$routeName);
16
    }
17
18
}
19