Completed
Pull Request — master (#129)
by
unknown
03:00
created

ManialinkPageAnswerDataProvider   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 3
c 0
b 0
f 0
lcom 0
cbo 1
dl 0
loc 22
ccs 0
cts 7
cp 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A onPlayerManialinkPageAnswer() 0 12 3
1
<?php
2
3
4
namespace eXpansion\Framework\Core\DataProviders;
5
6
7
class ManialinkPageAnswerDataProvider extends AbstractDataProvider
8
{
9
    /**
10
     * When a player uses an action dispatch information.
11
     *
12
     * @param $login
13
     * @param $actionId
14
     *
15
     */
16
    public function onPlayerManialinkPageAnswer($playerUid, $login, $actionId, array $entries)
0 ignored issues
show
Unused Code introduced by
The parameter $playerUid is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
17
    {
18
        $entryValues = array();
19
        if (count($entries))
20
        {
21
            foreach ($entries as $entry) {
22
                $entryValues[$entry['Name']] = $entry['Value'];
23
            }
24
        }
25
26
        $this->dispatch(__FUNCTION__, [$login, $actionId, $entryValues]);
27
    }
28
}