1 | <?php |
||
9 | class PusherBroadcaster extends AbstractBroadcaster implements BroadcasterInterface |
||
10 | { |
||
11 | /** |
||
12 | * @var Pusher |
||
13 | */ |
||
14 | private $pusher; |
||
15 | |||
16 | /** |
||
17 | * PusherBroadcaster constructor. |
||
18 | 9 | * @param Pusher $pusher |
|
19 | */ |
||
20 | 9 | public function __construct(Pusher $pusher) |
|
24 | |||
25 | /** |
||
26 | * @param Identity $identity |
||
27 | * @return mixed |
||
28 | * @throws \Exception |
||
29 | */ |
||
30 | public function auth(Identity $identity) |
||
41 | 3 | ||
42 | /** |
||
43 | 3 | * @param Identity $identity |
|
44 | * @param $response |
||
45 | * @return string signature |
||
46 | */ |
||
47 | public function validAuthenticationResponse(Identity $identity, $response) |
||
60 | |||
61 | /** |
||
62 | * Broadcast the given event. |
||
63 | * |
||
64 | * @param array $channels |
||
65 | * @param string $event |
||
66 | * @param array $payload |
||
67 | * @return void |
||
68 | */ |
||
69 | public function broadcast(array $channels, $event, array $payload = []) |
||
75 | |||
76 | /** |
||
77 | * Get the Pusher instance. |
||
78 | * |
||
79 | * @return Pusher |
||
80 | */ |
||
81 | public function getPusher() |
||
85 | } |
||
86 |
This check looks for a call to a parent method whose name is different than the method from which it is called.
Consider the following code:
The
getFirstName()
method in theSon
calls the wrong method in the parent class.