Passed
Push — master ( 848980...7bc374 )
by Arthur
04:30
created

WebNotificationCreatedEvent   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A broadcastAs() 0 2 1
A broadcastWith() 0 3 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: arthur
5
 * Date: 14.10.18
6
 * Time: 21:43
7
 */
8
9
namespace Foundation\Events;
10
11
12
use Illuminate\Notifications\Events\BroadcastNotificationCreated;
13
14
class WebNotificationCreatedEvent extends BroadcastNotificationCreated
15
{
16 8
    public function broadcastAs(){
17 8
        return 'notification.created';
18
    }
19
20
    /**
21
     * Get the data that should be sent with the broadcasted event.
22
     *
23
     * @return array
24
     */
25 8
    public function broadcastWith()
26
    {
27 8
        return $this->data;
28
    }
29
}
30