Completed
Push — develop ( d6a5df...b082c1 )
by René
02:36
created
Classes/Controller/BackendController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -72,8 +72,8 @@
 block discarded – undo
72 72
             /** @var \HDNET\OnpageIntegration\Domain\Model\Configuration $configuration */
73 73
             $configuration = $configurationRepository->findByUid(1);
74 74
 
75
-            $apiCallTable = 'zoom_' . $section . '_' . $call . '_table';
76
-            $apiCallGraph = 'zoom_' . $section . '_' . $call . '_graph';
75
+            $apiCallTable = 'zoom_'.$section.'_'.$call.'_table';
76
+            $apiCallGraph = 'zoom_'.$section.'_'.$call.'_graph';
77 77
 
78 78
             $this->view->assignMultiple([
79 79
                 'moduleName'    => TitleUtility::makeSubTitle($section),
Please login to merge, or discard this patch.
Classes/Utility/ArrayUtility.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -23,9 +23,9 @@  discard block
 block discarded – undo
23 23
     {
24 24
         $loader = GeneralUtility::makeInstance(\HDNET\OnpageIntegration\Loader\ApiResultLoader::class);
25 25
 
26
-        for ($i = 0; $i < count($metaDataArray[0]); $i++) {
26
+        for ($i = 0; $i<count($metaDataArray[0]); $i++) {
27 27
 
28
-            $graphDataArray = $loader->load('zoom_' . $section . '_' . $i . '_graph');
28
+            $graphDataArray = $loader->load('zoom_'.$section.'_'.$i.'_graph');
29 29
             $errorReportyKey = $metaDataArray[0][$i]['errors'];
30 30
 
31 31
             $metaDataArray[0][$i]['errors'] = self::errorReport($graphDataArray, $errorReportyKey);
@@ -41,19 +41,19 @@  discard block
 block discarded – undo
41 41
      *
42 42
      * @return int
43 43
      */
44
-    protected static function errorReport($graphApiCallResult,$errorReportKey) {
44
+    protected static function errorReport($graphApiCallResult, $errorReportKey) {
45 45
         $totalErrors = 0;
46 46
 
47
-        foreach($graphApiCallResult as $element) {
47
+        foreach ($graphApiCallResult as $element) {
48 48
 
49
-            if(in_array('sum', $errorReportKey)) {
50
-                if(in_array($errorReportKey['hidden'], $element)) {
49
+            if (in_array('sum', $errorReportKey)) {
50
+                if (in_array($errorReportKey['hidden'], $element)) {
51 51
                     continue;
52 52
                 }
53 53
                 $totalErrors += $element['count'];
54 54
             }
55 55
 
56
-            if(in_array($errorReportKey['show'], $element)) {
56
+            if (in_array($errorReportKey['show'], $element)) {
57 57
                 $totalErrors += $element['count'];
58 58
             }
59 59
         }
Please login to merge, or discard this patch.
Classes/Loader/ApiResultLoader.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
         if ($entry === false) {
47 47
             try {
48 48
                 $entry = $this->dataService->getApiResult($key);
49
-            }catch (ApiErrorException $e) {
49
+            } catch (ApiErrorException $e) {
50 50
 
51 51
             }
52 52
             $this->persister->persist($entry, $key);
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
         if ($entry === false) {
47 47
             try {
48 48
                 $entry = $this->dataService->getApiResult($key);
49
-            }catch (ApiErrorException $e) {
49
+            } catch (ApiErrorException $e) {
50 50
 
51 51
             }
52 52
             $this->persister->persist($entry, $key);
Please login to merge, or discard this patch.
Classes/Service/DataService.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@
 block discarded – undo
79 79
         foreach ($keys as $key) {
80 80
             try {
81 81
                 $results[$key] = $this->getApiResult($key);
82
-            }catch (ApiErrorException $e) {
82
+            } catch (ApiErrorException $e) {
83 83
                 continue;
84 84
             }
85 85
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@
 block discarded – undo
79 79
         foreach ($keys as $key) {
80 80
             try {
81 81
                 $results[$key] = $this->getApiResult($key);
82
-            }catch (ApiErrorException $e) {
82
+            } catch (ApiErrorException $e) {
83 83
                 continue;
84 84
             }
85 85
 
Please login to merge, or discard this patch.
Classes/Service/ApiCallService.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
             $this->checkForCurl();
28 28
 
29 29
             return $this->send($json);
30
-        }catch (UnavailableException $e) {
30
+        } catch (UnavailableException $e) {
31 31
 
32 32
         }
33 33
     }
@@ -66,15 +66,15 @@  discard block
 block discarded – undo
66 66
             CURLOPT_HTTPHEADER,
67 67
             array(
68 68
                 'Content-Type: application/json',
69
-                'Content-Length: ' . strlen($data)
69
+                'Content-Length: '.strlen($data)
70 70
             )
71 71
         );
72 72
         $return = curl_exec($ch);
73 73
         $code   = curl_getinfo($ch, CURLINFO_HTTP_CODE);
74
-        if ($code >= 500) {
74
+        if ($code>=500) {
75 75
             throw new UnavailableException('The API could not be reached.');
76 76
         }
77
-        if ($code >= 400) {
77
+        if ($code>=400) {
78 78
             throw new UnavailableException('There has been an error reaching the API.');
79 79
         }
80 80
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
             $this->checkForCurl();
28 28
 
29 29
             return $this->send($json);
30
-        }catch (UnavailableException $e) {
30
+        } catch (UnavailableException $e) {
31 31
 
32 32
         }
33 33
     }
Please login to merge, or discard this patch.