Passed
Branch init (bfa39e)
by Pulkit
02:44
created
src/Http/Http.php 2 patches
Unused Use Statements   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,12 +1,12 @@
 block discarded – undo
1 1
 <?php
2 2
 namespace Sourceout\LastFm\Http;
3 3
 
4
+use Http\Client\Exception\TransferException;
4 5
 use Http\Client\HttpClient;
5
-use Http\Message\MessageFactory;
6 6
 use Http\Discovery\HttpClientDiscovery;
7
-use Psr\Http\Message\ResponseInterface;
8 7
 use Http\Discovery\MessageFactoryDiscovery;
9
-use Http\Client\Exception\TransferException;
8
+use Http\Message\MessageFactory;
9
+use Psr\Http\Message\ResponseInterface;
10 10
 use Sourceout\LastFm\Exception\HttpTransferException;
11 11
 
12 12
 class Http implements HttpInterface
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
             return $this->getHttpClient()->sendRequest($request);
35 35
         } catch (TransferException $e) {
36 36
             throw new HttpTransferException(
37
-                "Error while requesting data". $e->getMessage(),
37
+                "Error while requesting data".$e->getMessage(),
38 38
                 $e->getCode(),
39 39
                 $e
40 40
             );
Please login to merge, or discard this patch.
src/Services/GeoService.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
      * @param string $country
10 10
      * @param integer $page
11 11
      * @param integer $limit
12
-     * @return mixed
12
+     * @return \Tightenco\Collect\Support\Collection
13 13
      */
14 14
     public function getTopArtists(
15 15
         string $country,
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
      * @param string $location
30 30
      * @param integer $limit
31 31
      * @param integer $page
32
-     * @return mixed
32
+     * @return \Tightenco\Collect\Support\Collection
33 33
      */
34 34
     public function getTopTracks(
35 35
         string $country,
Please login to merge, or discard this patch.
src/Client.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -42,13 +42,13 @@  discard block
 block discarded – undo
42 42
      */
43 43
     public function registerCustomProviders(array $providers) : void
44 44
     {
45
-        foreach($providers as $provider) {
45
+        foreach ($providers as $provider) {
46 46
             if (!class_exists($provider)) {
47 47
                 throw new ProviderDoesNotExistException(
48 48
                     "Provider {$provider} does not exists"
49 49
                 );
50 50
             } else if (
51
-                ! (array_intersect(
51
+                !(array_intersect(
52 52
                         $this->providerInterfaces,
53 53
                         class_implements($provider)
54 54
                     ) == $this->providerInterfaces
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
     ) : ServiceFactory
76 76
     {
77 77
         $class = get_class($provider);
78
-        if (! in_array($class, $this->getRegisteredProviders() )) {
78
+        if (!in_array($class, $this->getRegisteredProviders())) {
79 79
             throw new UnregisteredProviderException(
80 80
                 "Provider {$class} is not registered"
81 81
             );
Please login to merge, or discard this patch.