Passed
Pull Request — master (#263)
by Christopher
02:56
created
src/POData/Writers/Json/JsonWriter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -207,7 +207,7 @@
 block discarded – undo
207 207
 
208 208
             case 'Edm.DateTime':
209 209
                 $dateTime          = new DateTime($value, new DateTimeZone('UTC'));
210
-                $formattedDateTime = $dateTime->format('U') * 1000;
210
+                $formattedDateTime = $dateTime->format('U')*1000;
211 211
                 $this->writeCore('/Date(' . $formattedDateTime . ')/', /* quotes */ true);
212 212
                 break;
213 213
 
Please login to merge, or discard this patch.
src/POData/BatchProcessor/ChangeSetParser.php 1 patch
Spacing   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -116,8 +116,7 @@  discard block
 block discarded – undo
116 116
 
117 117
         $response = '';
118 118
         $splitter = false === $this->changeSetBoundary ?
119
-            '' :
120
-            '--' . $this->changeSetBoundary . $ODataEOL;
119
+            '' : '--' . $this->changeSetBoundary . $ODataEOL;
121 120
         $raw = $this->getRawRequests();
122 121
         foreach ($raw as $contentID => &$workingObject) {
123 122
             $headers = $workingObject->outgoingResponse()->getHeaders();
@@ -139,16 +138,14 @@  discard block
 block discarded – undo
139 138
         }
140 139
         $response .= trim($splitter);
141 140
         $response .= false === $this->changeSetBoundary ?
142
-            $ODataEOL :
143
-            '--' . $ODataEOL;
141
+            $ODataEOL : '--' . $ODataEOL;
144 142
         $response = 'Content-Length: ' .
145 143
             strlen($response) .
146 144
             $ODataEOL .
147 145
             $ODataEOL .
148 146
             $response;
149 147
         $response = false === $this->changeSetBoundary ?
150
-            $response :
151
-            'Content-Type: multipart/mixed; boundary=' .
148
+            $response : 'Content-Type: multipart/mixed; boundary=' .
152 149
             $this->changeSetBoundary .
153 150
             $ODataEOL .
154 151
             $response;
Please login to merge, or discard this patch.
src/POData/BatchProcessor/IncomingChangeSetRequest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
 
21 21
         $inboundRequestHeaders = $this->setupHeaders(strtok("\n"));
22 22
 
23
-        $RequestBody                                        = trim($RequestBody);
23
+        $RequestBody = trim($RequestBody);
24 24
 
25 25
         $host     = $_SERVER['HTTP_HOST'] ?? $_SERVER['SERVER_NAME'] ?? $_SERVER['SERVER_ADDR'] ?? 'localhost';
26 26
         $protocol = $_SERVER['PROTOCOL'] = isset($_SERVER['HTTPS']) && !empty($_SERVER['HTTPS']) ? 'https' : 'http';
Please login to merge, or discard this patch.
src/POData/HttpProcessUtility.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -414,7 +414,7 @@
 block discarded – undo
414 414
 
415 415
         $textLen = strlen($text);
416 416
         if ($textIndex >= $textLen || '.' != $text[$textIndex]) {
417
-            return $qualityValue * 1000;
417
+            return $qualityValue*1000;
418 418
         }
419 419
 
420 420
         ++$textIndex;
Please login to merge, or discard this patch.
src/POData/ObjectModel/CynicSerialiser.php 1 patch
Spacing   +6 added lines, -7 removed lines patch added patch discarded remove patch
@@ -139,13 +139,13 @@  discard block
 block discarded – undo
139 139
 
140 140
         $baseUri = $this->isBaseWritten ? null : $this->absoluteServiceUriWithSlash;
141 141
         $this->isBaseWritten = true;
142
-        $entries = array_map(function($entry){
142
+        $entries = array_map(function ($entry) {
143 143
             return $this->writeTopLevelElement(
144 144
                 $entry instanceof QueryResult ? $entry : new QueryResult($entry)
145 145
             );
146 146
         }, $res);
147 147
 
148
-        $odata               = new ODataFeed(
148
+        $odata = new ODataFeed(
149 149
             $this->getRequest()->getRequestUrl()->getUrlAsString(),
150 150
             new ODataTitle($this->getRequest()->getContainerName()),
151 151
             new ODataLink(
@@ -155,8 +155,7 @@  discard block
 block discarded – undo
155 155
                 $this->getRequest()->getIdentifier()
156 156
             ),
157 157
             $this->getRequest()->queryType == QueryType::ENTITIES_WITH_COUNT() ?
158
-                $this->getRequest()->getCountValue() :
159
-                null,
158
+                $this->getRequest()->getCountValue() : null,
160 159
             null,
161 160
             $entries,
162 161
             $this->getUpdated()->format(DATE_ATOM),
@@ -169,7 +168,7 @@  discard block
 block discarded – undo
169 168
         $pageSize    = $this->getService()->getConfiguration()->getEntitySetPageSize($resourceSet);
170 169
         $requestTop  = $this->getRequest()->getTopOptionCount() ?? $pageSize + 1;
171 170
         if (true === $entryObjects->hasMore && $requestTop > $pageSize) {
172
-            $odata->nextPageLink            = new ODataLink(
171
+            $odata->nextPageLink = new ODataLink(
173 172
                 ODataConstants::ATOM_LINK_NEXT_ATTRIBUTE_STRING,
174 173
                 null,
175 174
                 null,
@@ -739,7 +738,7 @@  discard block
 block discarded – undo
739 738
             return false;
740 739
         }
741 740
 
742
-        return 0 == ($value % 4);
741
+        return 0 == ($value%4);
743 742
     }
744 743
 
745 744
     /**
@@ -870,7 +869,7 @@  discard block
 block discarded – undo
870 869
                      ODataConstants::HTTPQUERY_STRING_EXPAND,
871 870
                      ODataConstants::HTTPQUERY_STRING_ORDERBY,
872 871
                      ODataConstants::HTTPQUERY_STRING_INLINECOUNT,
873
-                     ODataConstants::HTTPQUERY_STRING_SELECT,] as $queryOption) {
872
+                     ODataConstants::HTTPQUERY_STRING_SELECT, ] as $queryOption) {
874 873
             $value = $this->getService()->getHost()->getQueryStringItem($queryOption);
875 874
             if (null !== $value) {
876 875
                 if (null !== $queryParameterString) {
Please login to merge, or discard this patch.