Test Failed
Pull Request — master (#38)
by Patrick
14:01
created
src/ForecastAutomation/ProjektronClient/Business/ProjektronApi.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -38,14 +38,14 @@  discard block
 block discarded – undo
38 38
         $savedActivities = 0;
39 39
         foreach ($activityDtoCollection as $activityDto) {
40 40
             $writeTimeRegistration = [
41
-                'person' => (int) $this->forecastConfigDto->forecastPersonId,
41
+                'person' => (int)$this->forecastConfigDto->forecastPersonId,
42 42
                 'task' => $this->findTaskIdToNeedle($activityDto->needle),
43 43
                 'time_registered' => $activityDto->duration,
44 44
                 'date' => $activityDto->created->format('Y-m-d'),
45 45
                 'notes' => $activityDto->description,
46 46
             ];
47 47
             $writeResponse = $this->callPostApi(self::TIME_REGISTRATIONS_ENDPOINT, $writeTimeRegistration);
48
-            $this->logFacade->info('activity sent to forecast.', (array) $writeResponse);
48
+            $this->logFacade->info('activity sent to forecast.', (array)$writeResponse);
49 49
             ++$savedActivities;
50 50
         }
51 51
 
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
 
64 64
     private function callGetApi(string $path): array
65 65
     {
66
-        if (! $this->cacheFacade->has($path)) {
66
+        if (!$this->cacheFacade->has($path)) {
67 67
             $res = $this->guzzleClient->request(
68 68
                 'GET',
69 69
                 $path,
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
                     'headers' => ['X-FORECAST-API-KEY' => $this->forecastConfigDto->forecastApiKey],
72 72
                 ]
73 73
             );
74
-            $forecastResponse = json_decode((string) $res->getBody(), null, JSON_PARTIAL_OUTPUT_ON_ERROR, JSON_THROW_ON_ERROR);
74
+            $forecastResponse = json_decode((string)$res->getBody(), null, JSON_PARTIAL_OUTPUT_ON_ERROR, JSON_THROW_ON_ERROR);
75 75
             $this->cacheFacade->set($path, $forecastResponse);
76 76
         } else {
77 77
             $forecastResponse = $this->cacheFacade->get($path);
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
             ]
96 96
         );
97 97
 
98
-        return json_decode((string) $res->getBody(), null, JSON_PARTIAL_OUTPUT_ON_ERROR, JSON_THROW_ON_ERROR);
98
+        return json_decode((string)$res->getBody(), null, JSON_PARTIAL_OUTPUT_ON_ERROR, JSON_THROW_ON_ERROR);
99 99
     }
100 100
 
101 101
     private function findTaskIdToNeedle(string $taskNeedle): int
@@ -106,6 +106,6 @@  discard block
 block discarded – undo
106 106
             }
107 107
         }
108 108
 
109
-        return (int) $this->forecastConfigDto->forecastFallbackTaskId;
109
+        return (int)$this->forecastConfigDto->forecastFallbackTaskId;
110 110
     }
111 111
 }
Please login to merge, or discard this patch.
ProjektronClient/Shared/Plugin/ProjektronClientQueuePluginPlugin.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
             $messageDto->data['needle'],
42 42
             $messageDto->data['description'],
43 43
             new \DateTime($messageDto->data['created']),
44
-            (int) $messageDto->data['duration']
44
+            (int)$messageDto->data['duration']
45 45
         );
46 46
     }
47 47
 }
Please login to merge, or discard this patch.
src/ForecastAutomation/JiraClient/JiraClientFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@
 block discarded – undo
26 26
             $_ENV['JIRA_USER'],
27 27
             true,
28 28
             $_ENV['JIRA_TOKEN'],
29
-            (int) $_ENV['JIRA_MAX_RESULTS'],
29
+            (int)$_ENV['JIRA_MAX_RESULTS'],
30 30
             $_ENV['JIRA_QUERY'],
31 31
         );
32 32
     }
Please login to merge, or discard this patch.
src/ForecastAutomation/JiraClient/Business/JiraCollector.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@
 block discarded – undo
40 40
         foreach ($ticketList as $issueKey) {
41 41
             $comments = $this->jiraClient->getComments($issueKey);
42 42
             foreach ($comments->comments as $comment) {
43
-                if (($comment->updated>= date('Y-m-d H:i', strtotime($startDate)))
43
+                if (($comment->updated >= date('Y-m-d H:i', strtotime($startDate)))
44 44
                     && (isset($comment->author->emailAddress) && $comment->author->emailAddress === $this->jiraConfigDto->jiraUser)) {
45 45
                     $jiraActivities[$issueKey][] = $comment;
46 46
                 }
Please login to merge, or discard this patch.