WsRequest   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 3
lcom 0
cbo 1
dl 0
loc 19
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 8 1
A __get() 0 7 2
1
<?php
2
3
namespace Shamaseen\Laravel\Ratchet\Requests;
4
class WsRequest extends \Illuminate\Support\Collection
5
{
6
    public function __construct($items = [])
7
    {
8
        unset($items['session']);
9
        parent::__construct($items);
10
11
        $this->put('route',$this->get('route'));
12
        $this->forget('route');
13
    }
14
15
    public function __get($property)
16
    {
17
        if($this->has($property))
18
            return $this->get($property);
19
20
        return Parent::get($property);
21
    }
22
}
23