Completed
Push — master ( 66b80e...3455d2 )
by Maxim
02:34
created
src/AmoCRMClient.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -143,7 +143,7 @@
 block discarded – undo
143 143
     private function auth(UserInterface $user)
144 144
     {
145 145
         $request = new Request(
146
-            'POST', $user->getAmoCRMDomain() . "private/api/auth.php?type=json", [], \GuzzleHttp\json_encode(
146
+            'POST', $user->getAmoCRMDomain()."private/api/auth.php?type=json", [], \GuzzleHttp\json_encode(
147 147
                 [
148 148
                     'USER_LOGIN' => $user->getAmoCRMLogin(),
149 149
                     'USER_HASH' => $user->getAmoCRMHash(),
Please login to merge, or discard this patch.
src/Method/CurrentAccount.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
     public function buildRequest()
19 19
     {
20 20
         $request = new Request(
21
-            'GET', $this->user->getAmoCRMDomain() . 'private/api/v2/json/accounts/current'
21
+            'GET', $this->user->getAmoCRMDomain().'private/api/v2/json/accounts/current'
22 22
         );
23 23
 
24 24
         return $request;
Please login to merge, or discard this patch.
src/Entity/CustomField.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
     {
30 30
         return [
31 31
             'id' => $this->id,
32
-            'values' => array_map(function (Value $value) {
32
+            'values' => array_map(function(Value $value) {
33 33
                 return $value->toAmoArray();
34 34
             }, $this->values)
35 35
         ];
Please login to merge, or discard this patch.
src/SessionStorage/FileSessionStorage.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
      */
37 37
     public function save(Session $session, UserInterface $user)
38 38
     {
39
-        $filename = $this->sessionPath . $user->getAmoCRMLogin();
39
+        $filename = $this->sessionPath.$user->getAmoCRMLogin();
40 40
         if (is_dir($this->sessionPath)) {
41 41
             if (file_put_contents($filename, $session->getId())) {
42 42
                 return;
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
      */
54 54
     public function getActive(UserInterface $user)
55 55
     {
56
-        $filename = $this->sessionPath . $user->getAmoCRMLogin();
56
+        $filename = $this->sessionPath.$user->getAmoCRMLogin();
57 57
         if (file_exists($filename)) {
58 58
             if ($data = file_get_contents($filename)) {
59 59
                 return new Session($data);
Please login to merge, or discard this patch.
src/Entity/Contact.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -194,7 +194,7 @@
 block discarded – undo
194 194
             'linked_leads_id' => $this->linkedLeadsID,
195 195
             'company_name' => $this->companyName,
196 196
             'custom_fields' => array_map(
197
-                function (AmoEntityInterface $customField) {
197
+                function(AmoEntityInterface $customField) {
198 198
                     return $customField->toAmoArray();
199 199
                 },
200 200
                 $this->customFields
Please login to merge, or discard this patch.
examples/accounts.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 use mb24dev\AmoCRM\SessionStorage\FileSessionStorage;
9 9
 use mb24dev\AmoCRM\User\User;
10 10
 
11
-require_once __DIR__ . '/../vendor/autoload.php';
11
+require_once __DIR__.'/../vendor/autoload.php';
12 12
 
13 13
 // store strategy for sessions
14 14
 $fileStorage = new FileSessionStorage('/tmp/amocrm/');
@@ -27,4 +27,4 @@  discard block
 block discarded – undo
27 27
     new Method\CurrentAccount($user, new ArrayResponseTransformer())
28 28
 );
29 29
 
30
-echo 'Account: ' . print_r($result, true);
30
+echo 'Account: '.print_r($result, true);
Please login to merge, or discard this patch.
examples/contactSet.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
 use mb24dev\AmoCRM\SessionStorage\FileSessionStorage;
11 11
 use mb24dev\AmoCRM\User\User;
12 12
 
13
-require_once __DIR__ . '/../vendor/autoload.php';
13
+require_once __DIR__.'/../vendor/autoload.php';
14 14
 
15 15
 // store strategy for sessions
16 16
 $fileStorage = new FileSessionStorage('/tmp/amocrm/');
@@ -49,4 +49,4 @@  discard block
 block discarded – undo
49 49
 
50 50
 $result = $amoCRMClient->exec($contactSet);
51 51
 
52
-echo 'ContactSet result: ' . print_r($result, true);
52
+echo 'ContactSet result: '.print_r($result, true);
Please login to merge, or discard this patch.
examples/leadSet.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
 use mb24dev\AmoCRM\SessionStorage\FileSessionStorage;
11 11
 use mb24dev\AmoCRM\User\User;
12 12
 
13
-require_once __DIR__ . '/../vendor/autoload.php';
13
+require_once __DIR__.'/../vendor/autoload.php';
14 14
 
15 15
 // store strategy for sessions
16 16
 $fileStorage = new FileSessionStorage('/tmp/amocrm/');
@@ -48,4 +48,4 @@  discard block
 block discarded – undo
48 48
 
49 49
 $result = $amoCRMClient->exec($leadSet);
50 50
 
51
-echo 'LeadSet result: ' . print_r($result, true);
51
+echo 'LeadSet result: '.print_r($result, true);
Please login to merge, or discard this patch.
src/Entity/Lead.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -194,7 +194,7 @@
 block discarded – undo
194 194
             'linked_leads_id' => $this->linkedLeadsID,
195 195
             'company_name' => $this->companyName,
196 196
             'custom_fields' => array_map(
197
-                function (AmoEntityInterface $customField) {
197
+                function(AmoEntityInterface $customField) {
198 198
                     return $customField->toAmoArray();
199 199
                 },
200 200
                 $this->customFields
Please login to merge, or discard this patch.