Failed Conditions
Push — future/ConfuenceWrapper ( 63d44f )
by
unknown
06:07
created
src/ConfluenceImporter/Service/Confluence/Instance.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,9 +1,9 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Creator: adamgrabek
4
- * Date: 13.01.2016
5
- * Time: 15:06
6
- */
3
+     * Creator: adamgrabek
4
+     * Date: 13.01.2016
5
+     * Time: 15:06
6
+     */
7 7
 
8 8
 namespace CodeMine\ConfluenceImporter\Service\Confluence;
9 9
 
Please login to merge, or discard this patch.
src/ConfluenceImporter/Service/Confluence.php 3 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,6 @@
 block discarded – undo
5 5
 use CodeMine\ConfluenceImporter\Documentation\PageInterface;
6 6
 use CodeMine\ConfluenceImporter\Service\Confluence\InstanceInterface;
7 7
 use GuzzleHttp\ClientInterface;
8
-use GuzzleHttp\Exception\BadResponseException;
9 8
 use GuzzleHttp\Exception\ClientException;
10 9
 use GuzzleHttp\Psr7\Request;
11 10
 
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
             ]
61 61
         ];
62 62
 
63
-        if (isset($parentPage)){
63
+        if (isset($parentPage)) {
64 64
             $bodyArray['ancestors'] = [
65 65
               ['id' => $pageId]
66 66
                 ];
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
         try {
87 87
             $response = $this->client->send($request); //TODO: put in try and find solution for exception on same page name
88 88
             var_dump($response);
89
-        }catch(ClientException $e){
89
+        } catch (ClientException $e) {
90 90
 
91 91
             echo 'ERROR!!!';
92 92
             var_dump($e->getMessage());
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
 
98 98
         $stdBody = json_decode($returnBody->getContents());
99 99
 
100
-        $pageId = (string)$stdBody->id;
100
+        $pageId = (string) $stdBody->id;
101 101
 
102 102
         $bodyArray = [
103 103
             'type' => 'page',
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 
132 132
         try {
133 133
             $response = $this->client->send($request);
134
-        }catch(\Exception $e){
134
+        } catch (\Exception $e) {
135 135
             var_dump('EEEEEEEEEEEEEEEERRRROOOOOOOOOOOOR');
136 136
             var_dump($e->getMessage());
137 137
             die;
@@ -153,9 +153,9 @@  discard block
 block discarded – undo
153 153
 
154 154
 //        var_dump($stdBody);
155 155
 //        die;
156
-        if ($response->getStatusCode() == 200 && count($stdBody->results) == 1){
156
+        if ($response->getStatusCode() == 200 && count($stdBody->results) == 1) {
157 157
 
158
-            $id = (string)$stdBody->results[0]->id;
158
+            $id = (string) $stdBody->results[0]->id;
159 159
 
160 160
 //            var_dump($id);die;
161 161
             return $id;
Please login to merge, or discard this patch.
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
         try {
87 87
             $response = $this->client->send($request); //TODO: put in try and find solution for exception on same page name
88 88
             var_dump($response);
89
-        }catch(ClientException $e){
89
+        } catch(ClientException $e){
90 90
 
91 91
             echo 'ERROR!!!';
92 92
             var_dump($e->getMessage());
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 
132 132
         try {
133 133
             $response = $this->client->send($request);
134
-        }catch(\Exception $e){
134
+        } catch(\Exception $e){
135 135
             var_dump('EEEEEEEEEEEEEEEERRRROOOOOOOOOOOOR');
136 136
             var_dump($e->getMessage());
137 137
             die;
Please login to merge, or discard this patch.