Completed
Branch 2.0.0 (bd9367)
by Chubarov
04:25
created
src/Actions/Delete.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -63,11 +63,11 @@  discard block
 block discarded – undo
63 63
     {
64 64
         $parameters = str_replace(' ', '%20', $this->url);
65 65
 
66
-        $url        = $this->kernel->getCollection() . $parameters;
67
-        $urlHome    = config($this->kernel->getPrefixConfig() . '.UrlHome');
66
+        $url        = $this->kernel->getCollection().$parameters;
67
+        $urlHome    = config($this->kernel->getPrefixConfig().'.UrlHome');
68 68
 
69 69
 
70
-            $response =  $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome . $url,
70
+            $response = $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome.$url,
71 71
                 [
72 72
                     'headers' => [
73 73
                         'HTTP/1.0',
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
             $body = $response->getBody();
85 85
             $this->kernel->getHandler()->parse($body->getContents());
86 86
 
87
-            if ( $response->getStatusCode() == 401 && $response->getReasonPhrase() == 'Unauthorized' )
87
+            if ($response->getStatusCode() == 401 && $response->getReasonPhrase() == 'Unauthorized')
88 88
             {
89 89
                 $this->kernel->authentication();
90 90
                 $this->query();
Please login to merge, or discard this patch.
src/Actions/Create.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -53,10 +53,10 @@  discard block
 block discarded – undo
53 53
     {
54 54
         $parameters = str_replace(' ', '%20', $this->url);
55 55
 
56
-        $url        = $this->kernel->getCollection() . $parameters;
57
-        $urlHome    = config($this->kernel->getPrefixConfig() . '.UrlHome');
56
+        $url        = $this->kernel->getCollection().$parameters;
57
+        $urlHome    = config($this->kernel->getPrefixConfig().'.UrlHome');
58 58
 
59
-        $response   =  $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome . $url,
59
+        $response   = $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome.$url,
60 60
                 [
61 61
                     'headers' => [
62 62
                         'HTTP/1.0',
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
                     'body' => $this->kernel->getHandler()->create($this->data),
71 71
                     'http_errors' => false
72 72
                 ]);
73
-        $body       = $response->getBody();
73
+        $body = $response->getBody();
74 74
         $this->kernel->getHandler()->parse($body->getContents());
75 75
     }
76 76
 }
77 77
\ No newline at end of file
Please login to merge, or discard this patch.
src/Actions/Read.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -75,8 +75,8 @@  discard block
 block discarded – undo
75 75
      */
76 76
     public function filterConstructor($strRequest)
77 77
     {
78
-        $ParameterQuery =  '$filter=';
79
-        $ParameterQuery.=  $strRequest;
78
+        $ParameterQuery = '$filter=';
79
+        $ParameterQuery .= $strRequest;
80 80
         $this->concatenationUrlCurl($ParameterQuery);
81 81
         return $this;
82 82
     }
@@ -93,13 +93,13 @@  discard block
 block discarded – undo
93 93
     public function orderBy($whatSort, $param = 'asc')
94 94
     {
95 95
         $ParameterQuery = '$orderby=';
96
-        $ParameterQuery.=  ucfirst($whatSort);
96
+        $ParameterQuery .= ucfirst($whatSort);
97 97
 
98
-        if ( empty($param) === false ) {
98
+        if (empty($param) === false) {
99 99
             if ($param != 'desc' && $param != 'asc') {
100 100
                 throw new \Exception('no valid orderby parameters');
101 101
             }
102
-            $ParameterQuery.=  " ".$param;
102
+            $ParameterQuery .= " ".$param;
103 103
         }
104 104
          $this->concatenationUrlCurl($ParameterQuery);
105 105
 
@@ -130,7 +130,7 @@  discard block
 block discarded – undo
130 130
      */
131 131
     public function amount($amountMax = null)
132 132
     {
133
-        Assert::that($amountMax,'You must specify a numeric parameter for the amount of the method')->integer();
133
+        Assert::that($amountMax, 'You must specify a numeric parameter for the amount of the method')->integer();
134 134
         $ParameterQuery = '$top='.$amountMax;
135 135
         $this->concatenationUrlCurl($ParameterQuery);
136 136
         return $this;
@@ -142,10 +142,10 @@  discard block
 block discarded – undo
142 142
     private function query()
143 143
     {
144 144
         $parameters   = str_replace(' ', '%20', $this->url);
145
-        $url          = $this->kernel->getCollection() . $parameters;
146
-        $urlHome      = config($this->kernel->getPrefixConfig() . '.UrlHome');
145
+        $url          = $this->kernel->getCollection().$parameters;
146
+        $urlHome      = config($this->kernel->getPrefixConfig().'.UrlHome');
147 147
 
148
-        $response     =  $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome . $url,
148
+        $response     = $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome.$url,
149 149
                 [
150 150
                     'headers' => [
151 151
                         'HTTP/1.0',
@@ -159,10 +159,10 @@  discard block
 block discarded – undo
159 159
                     'http_errors' => false
160 160
                 ]);
161 161
 
162
-        $body         = $response->getBody();
162
+        $body = $response->getBody();
163 163
         $this->kernel->getHandler()->parse($body->getContents());
164 164
 
165
-        if ( $response->getStatusCode() == 401 && $response->getReasonPhrase() == 'Unauthorized' )
165
+        if ($response->getStatusCode() == 401 && $response->getReasonPhrase() == 'Unauthorized')
166 166
         {
167 167
             $this->kernel->authentication();
168 168
             $this->query();
Please login to merge, or discard this patch.
src/Actions/Update.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -80,10 +80,10 @@  discard block
 block discarded – undo
80 80
     private function query()
81 81
     {
82 82
         $parameters = str_replace(' ', '%20', $this->url);
83
-        $url        = $this->kernel->getCollection() . $parameters;
84
-        $urlHome    = config($this->kernel->getPrefixConfig() . '.UrlHome');
83
+        $url        = $this->kernel->getCollection().$parameters;
84
+        $urlHome    = config($this->kernel->getPrefixConfig().'.UrlHome');
85 85
 
86
-        $response   =  $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome . $url,
86
+        $response   = $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome.$url,
87 87
             [
88 88
                 'headers' => [
89 89
                     'HTTP/1.0',
@@ -97,11 +97,11 @@  discard block
 block discarded – undo
97 97
                 'body' => $this->kernel->getHandler()->create($this->data),
98 98
                 'http_errors' => false
99 99
             ]);
100
-        $body       = $response->getBody();
100
+        $body = $response->getBody();
101 101
 
102 102
         $this->kernel->getHandler()->parse($body->getContents());
103 103
 
104
-        if ( $response->getStatusCode() == 401 && $response->getReasonPhrase() == 'Unauthorized' )
104
+        if ($response->getStatusCode() == 401 && $response->getReasonPhrase() == 'Unauthorized')
105 105
         {
106 106
             $this->kernel->authentication();
107 107
             $this->query();
Please login to merge, or discard this patch.