Completed
Pull Request — master (#104)
by
unknown
04:57 queued 02:15
created
src/eXpansion/Bundle/MxKarma/Plugins/Connection.php 3 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -238,7 +238,7 @@
 block discarded – undo
238 238
      */
239 239
     public function getObject($data)
240 240
     {
241
-        $obj = (object)json_decode($data);
241
+        $obj = (object) json_decode($data);
242 242
         if ($obj->success === false) {
243 243
             $this->handleErrors($obj);
244 244
 
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -181,7 +181,7 @@
 block discarded – undo
181 181
 
182 182
     /**
183 183
      * loads votes from server
184
-     * @param array $players
184
+     * @param integer[] $players
185 185
      * @param bool $getVotesOnly
186 186
      */
187 187
     public function loadVotes($players = array(), $getVotesOnly = false)
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,6 @@
 block discarded – undo
30 30
 use eXpansion\Framework\Core\Storage\MapStorage;
31 31
 use Maniaplanet\DedicatedServer\Structures\GameInfos;
32 32
 use Maniaplanet\DedicatedServer\Structures\Map;
33
-use oliverde8\AsynchronousJobs\Job\CallbackCurl;
34 33
 
35 34
 /**
36 35
  * Description of Connection
Please login to merge, or discard this patch.
src/eXpansion/Framework/Core/Helpers/Http.php 1 patch
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -6,8 +6,6 @@
 block discarded – undo
6 6
 use eXpansion\Framework\Core\Helpers\Structures\HttpRequest;
7 7
 use eXpansion\Framework\Core\Helpers\Structures\HttpResult;
8 8
 use eXpansion\Framework\Core\Services\Application\AbstractApplication;
9
-use oliverde8\AsynchronousJobs\Job\CallbackCurl;
10
-use oliverde8\AsynchronousJobs\JobRunner;
11 9
 
12 10
 /**
13 11
  * Class Http
Please login to merge, or discard this patch.
src/eXpansion/Framework/Core/Helpers/JobRunner/Factory.php 2 patches
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -29,13 +29,13 @@
 block discarded – undo
29 29
     }
30 30
 
31 31
     /**
32
-     * @param $url
33
-     * @param $callback
32
+     * @param string $url
33
+     * @param callable $callback
34 34
      * @param null|mixed $additionalData
35 35
      * @param array $options
36 36
      *
37 37
      * @param array|\stdClass $parameters one dimensional array or \stdClass with post key-value pairs
38
-     * @return CallbackCurl
38
+     * @return Job
39 39
      */
40 40
     public function createCurlJob($url, $callback, $additionalData = null, $options = [], $parameters = [])
41 41
     {
Please login to merge, or discard this patch.
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -2,10 +2,8 @@
 block discarded – undo
2 2
 
3 3
 namespace eXpansion\Framework\Core\Helpers\JobRunner;
4 4
 
5
-use eXpansion\Framework\Core\DataProviders\Listener\ListenerInterfaceExpApplication;
6 5
 use eXpansion\Framework\Core\DataProviders\Listener\ListenerInterfaceExpTimer;
7 6
 use eXpansion\Framework\Core\Helpers\Structures\HttpRequest;
8
-use eXpansion\Framework\Core\Helpers\Structures\HttpResult;
9 7
 use oliverde8\AsynchronousJobs\Job;
10 8
 use oliverde8\AsynchronousJobs\Job\CallbackCurl;
11 9
 use oliverde8\AsynchronousJobs\JobRunner;
Please login to merge, or discard this patch.
src/eXpansion/Framework/Core/Helpers/Structures/HttpRequest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,6 +30,6 @@
 block discarded – undo
30 30
      */
31 31
     public function __toString()
32 32
     {
33
-        return (string)$this->response['response'];
33
+        return (string) $this->response['response'];
34 34
     }
35 35
 }
Please login to merge, or discard this patch.
src/eXpansion/Bundle/Maps/ChatCommand/Remove.php 1 patch
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -2,10 +2,8 @@
 block discarded – undo
2 2
 
3 3
 namespace eXpansion\Bundle\Maps\ChatCommand;
4 4
 
5
-use eXpansion\Bundle\AdminChat\ChatCommand\AbstractConnectionCommand;
6 5
 use eXpansion\Bundle\Maps\Plugins\ManiaExchange;
7 6
 use eXpansion\Bundle\Maps\Plugins\Maps;
8
-use eXpansion\Bundle\Maps\Services\JukeboxService;
9 7
 use eXpansion\Framework\AdminGroups\Helpers\AdminGroups;
10 8
 use Symfony\Component\Console\Input\InputArgument;
11 9
 use Symfony\Component\Console\Input\InputInterface;
Please login to merge, or discard this patch.
src/eXpansion/Bundle/Maps/Plugins/Gui/ManiaExchangeWindowFactory.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace eXpansion\Bundle\Maps\Plugins\Gui;
4 4
 
5
-use eXpansion\Bundle\Maps\Plugins\Jukebox;
6 5
 use eXpansion\Bundle\Maps\Plugins\ManiaExchange;
7 6
 use eXpansion\Bundle\Maps\Structure\MxInfo;
8 7
 use eXpansion\Framework\Core\Helpers\Http;
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -304,7 +304,7 @@
 block discarded – undo
304 304
 
305 305
     public function callbackSearch($login, $params, $args)
306 306
     {
307
-        $params = (object)$params;
307
+        $params = (object) $params;
308 308
 
309 309
         $this->modebox->setSelectedIndex($this->findIndex($this->tracksearch, $params->mode));
310 310
         $this->orderbox->setSelectedIndex($this->findIndex($this->order, $params->order));
Please login to merge, or discard this patch.
src/eXpansion/Framework/Core/Storage/MapStorage.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
      */
53 53
     public function getMap($uid)
54 54
     {
55
-        return AssociativeArray::getFromKey($this->maps, $uid,  new Map());
55
+        return AssociativeArray::getFromKey($this->maps, $uid, new Map());
56 56
     }
57 57
 
58 58
     /**
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
      */
65 65
     public function getMapByIndex($index)
66 66
     {
67
-        $map = array_slice($this->maps, (int)$index, 1, false);
67
+        $map = array_slice($this->maps, (int) $index, 1, false);
68 68
 
69 69
         return end($map);
70 70
     }
Please login to merge, or discard this patch.
src/eXpansion/Bundle/MxKarma/Plugins/MxKarma.php 3 patches
Doc Comments   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -87,6 +87,10 @@  discard block
 block discarded – undo
87 87
         $this->playerStorage = $playerStorage;
88 88
     }
89 89
 
90
+    /**
91
+     * @param string $login
92
+     * @param integer $vote
93
+     */
90 94
     public function setVote($login, $vote)
91 95
     {
92 96
         $player = $this->playerStorage->getPlayerInfo($login);
@@ -183,7 +187,6 @@  discard block
 block discarded – undo
183 187
     }
184 188
 
185 189
     /**
186
-     * @param MxRating $ratings
187 190
      * @return mixed
188 191
      */
189 192
     public function onMxKarmaVoteLoad(MxRating $mxRating)
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -15,7 +15,6 @@
 block discarded – undo
15 15
 use eXpansion\Framework\Core\Storage\Data\Player;
16 16
 use eXpansion\Framework\Core\Storage\PlayerStorage;
17 17
 use eXpansion\Framework\GameManiaplanet\DataProviders\Listener\ListenerInterfaceMpScriptMap;
18
-use eXpansion\Framework\GameManiaplanet\DataProviders\Listener\ListenerInterfaceMpScriptMatch;
19 18
 use Maniaplanet\DedicatedServer\Structures\Map;
20 19
 use Symfony\Component\Yaml\Yaml;
21 20
 use eXpansion\Bundle\MxKarma\Plugins\Connection as MxConnection;
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
         PlayerStorage $playerStorage
80 80
     ) {
81 81
 
82
-        $this->config = (object)Yaml::parse(file_get_contents('./app/config/plugins/mxkarma.yml'))['parameters'];
82
+        $this->config = (object) Yaml::parse(file_get_contents('./app/config/plugins/mxkarma.yml'))['parameters'];
83 83
         $this->console = $console;
84 84
         $this->dispatcher = $dispatcher;
85 85
         $this->chatNotification = $chatNotification;
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
             "vote" => $vote,
98 98
         ];
99 99
 
100
-        $this->changedVotes[$player->getLogin()] = new MxVote((object)$obj);
100
+        $this->changedVotes[$player->getLogin()] = new MxVote((object) $obj);
101 101
         $this->chatNotification->sendMessage('expansion_mxkarma.chat.votechanged', $login);
102 102
     }
103 103
 
Please login to merge, or discard this patch.
src/eXpansion/Bundle/MxKarma/Entity/MxVote.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -15,6 +15,6 @@
 block discarded – undo
15 15
     public function __construct($obj)
16 16
     {
17 17
         $this->login = $obj->login;
18
-        $this->vote = (int)$obj->vote;
18
+        $this->vote = (int) $obj->vote;
19 19
     }
20 20
 }
Please login to merge, or discard this patch.