Passed
Push — master ( 2b0361...4b9b04 )
by Bruce Pinheiro de
02:58
created
src/SumUpClientInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,5 +68,5 @@
 block discarded – undo
68 68
     /**
69 69
      * @return AccessToken
70 70
      */
71
-    public function getToken():? AccessToken;
71
+    public function getToken(): ? AccessToken;
72 72
 }
Please login to merge, or discard this patch.
src/Customer/Address.php 1 patch
Indentation   +372 added lines, -372 removed lines patch added patch discarded remove patch
@@ -8,390 +8,390 @@
 block discarded – undo
8 8
  */
9 9
 class Address implements AddressInterface
10 10
 {
11
-	/**
12
-	 * First address line
13
-	 *
14
-	 * @var string $line1
15
-	 */
16
-	protected $line1;
17
-	/**
18
-	 * Second address line
19
-	 *
20
-	 * @var string
21
-	 */
22
-	protected $line2;
23
-	/**
24
-	 * Address Country
25
-	 *
26
-	 * @var string
27
-	 */
28
-	protected $country;
29
-	/**
30
-	 * Address postal code
31
-	 *
32
-	 * @var string
33
-	 */
34
-	protected $postalCode;
35
-	/**
36
-	 * Address City
37
-	 *
38
-	 * @var string
39
-	 */
40
-	protected $city;
41
-	/**
42
-	 * @var string
43
-	 */
44
-	protected $countryEnName;
45
-	/**
46
-	 * @var string
47
-	 */
48
-	protected $countryNativeName;
49
-	/**
50
-	 * @var integer
51
-	 */
52
-	protected $regionId;
53
-	/**
54
-	 * @var string
55
-	 */
56
-	protected $regionName;
57
-	/**
58
-	 * @var string
59
-	 */
60
-	protected $postCode;
61
-	/**
62
-	 * @var string
63
-	 */
64
-	protected $landline;
65
-	/**
66
-	 * @var string
67
-	 */
68
-	protected $addressLine1;
69
-	/**
70
-	 * @var string
71
-	 */
72
-	protected $addressLine2;
73
-	/**
74
-	 * Address State
75
-	 *
76
-	 * @var string
77
-	 */
78
-	protected $state;
79
-
80
-	/**
81
-	 * Address constructor.
82
-	 * @param array|null $data
83
-	 */
11
+    /**
12
+     * First address line
13
+     *
14
+     * @var string $line1
15
+     */
16
+    protected $line1;
17
+    /**
18
+     * Second address line
19
+     *
20
+     * @var string
21
+     */
22
+    protected $line2;
23
+    /**
24
+     * Address Country
25
+     *
26
+     * @var string
27
+     */
28
+    protected $country;
29
+    /**
30
+     * Address postal code
31
+     *
32
+     * @var string
33
+     */
34
+    protected $postalCode;
35
+    /**
36
+     * Address City
37
+     *
38
+     * @var string
39
+     */
40
+    protected $city;
41
+    /**
42
+     * @var string
43
+     */
44
+    protected $countryEnName;
45
+    /**
46
+     * @var string
47
+     */
48
+    protected $countryNativeName;
49
+    /**
50
+     * @var integer
51
+     */
52
+    protected $regionId;
53
+    /**
54
+     * @var string
55
+     */
56
+    protected $regionName;
57
+    /**
58
+     * @var string
59
+     */
60
+    protected $postCode;
61
+    /**
62
+     * @var string
63
+     */
64
+    protected $landline;
65
+    /**
66
+     * @var string
67
+     */
68
+    protected $addressLine1;
69
+    /**
70
+     * @var string
71
+     */
72
+    protected $addressLine2;
73
+    /**
74
+     * Address State
75
+     *
76
+     * @var string
77
+     */
78
+    protected $state;
79
+
80
+    /**
81
+     * Address constructor.
82
+     * @param array|null $data
83
+     */
84 84
     public function __construct(?array $data = [])
85
-	{
86
-		$this->setAddressLine1($data['address_line1']??null);
87
-		$this->setAddressLine2($data['address_line2']??null);
88
-		$this->setCity($data['city']??null);
89
-		$this->setCountry($data['country']??null);
90
-		$this->setCountryEnName($data['country_en_name']??null);
91
-		$this->setCountryNativeName($data['country_native_name']??null);
92
-		$this->setRegionId($data['region_id']??null);
93
-		$this->setRegionName($data['region_name']??null);
94
-		$this->setPostCode($data['post_code']??null);
95
-		$this->setLandline($data['landline']??null);
96
-		$this->setLine1($data['line1']??null);
97
-		$this->setLine2($data['line2']??null);
98
-		$this->setPostalCode($data['postal_code']??null);
99
-		$this->setState($data['state']??null);
100
-	}
101
-
102
-	/**
103
-	 * Get $line1
104
-	 *
105
-	 * @return  string
106
-	 */
107
-	public function getLine1(): ?string
108
-	{
109
-		return $this->line1;
110
-	}
111
-
112
-	/**
113
-	 * Set $line1
114
-	 *
115
-	 * @param  string  $line1  $line1
116
-	 *
117
-	 * @return  AddressInterface
118
-	 */
119
-	public function setLine1(?string $line1): AddressInterface
120
-	{
121
-		$this->line1 = $line1;
122
-
123
-		return $this;
124
-	}
125
-
126
-	/**
127
-	 * Get second address line
128
-	 *
129
-	 * @return  string
130
-	 */
131
-	public function getLine2(): ?string
132
-	{
133
-		return $this->line2;
134
-	}
135
-
136
-	/**
137
-	 * Set second address line
138
-	 *
139
-	 * @param  string  $line2  Second address line
140
-	 *
141
-	 * @return  AddressInterface
142
-	 */
143
-	public function setLine2(?string $line2): AddressInterface
144
-	{
145
-		$this->line2 = $line2;
146
-
147
-		return $this;
148
-	}
149
-
150
-	/**
151
-	 * Get address Country
152
-	 *
153
-	 * @return  string
154
-	 */
155
-	public function getCountry(): ?string
156
-	{
157
-		return $this->country;
158
-	}
159
-
160
-	/**
161
-	 * Set address Country
162
-	 *
163
-	 * @param  string  $country  Address Country
164
-	 *
165
-	 * @return  AddressInterface
166
-	 */
167
-	public function setCountry(?string $country): AddressInterface
168
-	{
169
-		$this->country = $country;
170
-
171
-		return $this;
172
-	}
173
-
174
-	/**
175
-	 * Get address postal code
176
-	 *
177
-	 * @return  string
178
-	 */
179
-	public function getPostalCode(): ?string
180
-	{
181
-		return $this->postalCode;
182
-	}
183
-
184
-	/**
185
-	 * Set address postal code
186
-	 *
187
-	 * @param  string  $postalCode  Address postal code
188
-	 *
189
-	 * @return  AddressInterface
190
-	 */
191
-	public function setPostalCode(?string $postalCode): AddressInterface
192
-	{
193
-		$this->postalCode = $postalCode;
194
-
195
-		return $this;
196
-	}
197
-
198
-	/**
199
-	 * Get address City
200
-	 *
201
-	 * @return  string
202
-	 */
203
-	public function getCity(): ?string
204
-	{
205
-		return $this->city;
206
-	}
207
-
208
-	/**
209
-	 * Set address City
210
-	 *
211
-	 * @param  string  $city  Address City
212
-	 *
213
-	 * @return  AddressInterface
214
-	 */
215
-	public function setCity(?string $city): AddressInterface
216
-	{
217
-		$this->city = $city;
218
-
219
-		return $this;
220
-	}
221
-
222
-	/**
223
-	 * @return mixed
224
-	 */
225
-	public function getCountryEnName():? string
226
-	{
227
-		return $this->countryEnName;
228
-	}
229
-
230
-	/**
231
-	 * @param mixed $countryEnName
232
-	 * @return AddressInterface
233
-	 */
234
-	public function setCountryEnName($countryEnName): AddressInterface
235
-	{
236
-		$this->countryEnName = $countryEnName;
237
-
238
-		return $this;
239
-	}
240
-
241
-	/**
242
-	 * @return mixed
243
-	 */
244
-	public function getCountryNativeName():? string
245
-	{
246
-		return $this->countryNativeName;
247
-	}
85
+    {
86
+        $this->setAddressLine1($data['address_line1']??null);
87
+        $this->setAddressLine2($data['address_line2']??null);
88
+        $this->setCity($data['city']??null);
89
+        $this->setCountry($data['country']??null);
90
+        $this->setCountryEnName($data['country_en_name']??null);
91
+        $this->setCountryNativeName($data['country_native_name']??null);
92
+        $this->setRegionId($data['region_id']??null);
93
+        $this->setRegionName($data['region_name']??null);
94
+        $this->setPostCode($data['post_code']??null);
95
+        $this->setLandline($data['landline']??null);
96
+        $this->setLine1($data['line1']??null);
97
+        $this->setLine2($data['line2']??null);
98
+        $this->setPostalCode($data['postal_code']??null);
99
+        $this->setState($data['state']??null);
100
+    }
101
+
102
+    /**
103
+     * Get $line1
104
+     *
105
+     * @return  string
106
+     */
107
+    public function getLine1(): ?string
108
+    {
109
+        return $this->line1;
110
+    }
111
+
112
+    /**
113
+     * Set $line1
114
+     *
115
+     * @param  string  $line1  $line1
116
+     *
117
+     * @return  AddressInterface
118
+     */
119
+    public function setLine1(?string $line1): AddressInterface
120
+    {
121
+        $this->line1 = $line1;
122
+
123
+        return $this;
124
+    }
125
+
126
+    /**
127
+     * Get second address line
128
+     *
129
+     * @return  string
130
+     */
131
+    public function getLine2(): ?string
132
+    {
133
+        return $this->line2;
134
+    }
135
+
136
+    /**
137
+     * Set second address line
138
+     *
139
+     * @param  string  $line2  Second address line
140
+     *
141
+     * @return  AddressInterface
142
+     */
143
+    public function setLine2(?string $line2): AddressInterface
144
+    {
145
+        $this->line2 = $line2;
146
+
147
+        return $this;
148
+    }
149
+
150
+    /**
151
+     * Get address Country
152
+     *
153
+     * @return  string
154
+     */
155
+    public function getCountry(): ?string
156
+    {
157
+        return $this->country;
158
+    }
159
+
160
+    /**
161
+     * Set address Country
162
+     *
163
+     * @param  string  $country  Address Country
164
+     *
165
+     * @return  AddressInterface
166
+     */
167
+    public function setCountry(?string $country): AddressInterface
168
+    {
169
+        $this->country = $country;
170
+
171
+        return $this;
172
+    }
173
+
174
+    /**
175
+     * Get address postal code
176
+     *
177
+     * @return  string
178
+     */
179
+    public function getPostalCode(): ?string
180
+    {
181
+        return $this->postalCode;
182
+    }
183
+
184
+    /**
185
+     * Set address postal code
186
+     *
187
+     * @param  string  $postalCode  Address postal code
188
+     *
189
+     * @return  AddressInterface
190
+     */
191
+    public function setPostalCode(?string $postalCode): AddressInterface
192
+    {
193
+        $this->postalCode = $postalCode;
194
+
195
+        return $this;
196
+    }
197
+
198
+    /**
199
+     * Get address City
200
+     *
201
+     * @return  string
202
+     */
203
+    public function getCity(): ?string
204
+    {
205
+        return $this->city;
206
+    }
207
+
208
+    /**
209
+     * Set address City
210
+     *
211
+     * @param  string  $city  Address City
212
+     *
213
+     * @return  AddressInterface
214
+     */
215
+    public function setCity(?string $city): AddressInterface
216
+    {
217
+        $this->city = $city;
218
+
219
+        return $this;
220
+    }
221
+
222
+    /**
223
+     * @return mixed
224
+     */
225
+    public function getCountryEnName():? string
226
+    {
227
+        return $this->countryEnName;
228
+    }
229
+
230
+    /**
231
+     * @param mixed $countryEnName
232
+     * @return AddressInterface
233
+     */
234
+    public function setCountryEnName($countryEnName): AddressInterface
235
+    {
236
+        $this->countryEnName = $countryEnName;
237
+
238
+        return $this;
239
+    }
240
+
241
+    /**
242
+     * @return mixed
243
+     */
244
+    public function getCountryNativeName():? string
245
+    {
246
+        return $this->countryNativeName;
247
+    }
248 248
 
249 249
     /**
250 250
      * @param mixed $countryNativeName
251 251
      * @return AddressInterface
252 252
      */
253
-	public function setCountryNativeName(?string $countryNativeName): AddressInterface
254
-	{
255
-		$this->countryNativeName = $countryNativeName;
253
+    public function setCountryNativeName(?string $countryNativeName): AddressInterface
254
+    {
255
+        $this->countryNativeName = $countryNativeName;
256 256
 
257
-		return $this;
258
-	}
257
+        return $this;
258
+    }
259 259
 
260
-	/**
260
+    /**
261 261
      * @return int|null
262
-	 */
262
+     */
263 263
     public function getRegionId():? int
264
-	{
265
-		return $this->regionId;
266
-	}
264
+    {
265
+        return $this->regionId;
266
+    }
267 267
 
268
-	/**
268
+    /**
269 269
      * @param int|null $regionId
270 270
      * @return AddressInterface
271
-	 */
271
+     */
272 272
     public function setRegionId(?int $regionId): AddressInterface
273
-	{
274
-		$this->regionId = $regionId;
275
-
276
-		return $this;
277
-	}
278
-
279
-	/**
280
-	 * @return string|null
281
-	 */
282
-	public function getRegionName():? string
283
-	{
284
-		return $this->regionName;
285
-	}
286
-
287
-	/**
288
-	 * @param string|null $regionName
289
-	 * @return AddressInterface
290
-	 */
291
-	public function setRegionName(?string $regionName): AddressInterface
292
-	{
293
-		$this->regionName = $regionName;
294
-
295
-		return $this;
296
-	}
297
-
298
-	/**
299
-	 * @return string|null
300
-	 */
301
-	public function getPostCode():? string
302
-	{
303
-		return $this->postCode;
304
-	}
305
-
306
-	/**
307
-	 * @param string|null $postCode
308
-	 * @return AddressInterface
309
-	 */
310
-	public function setPostCode(?string $postCode): AddressInterface
311
-	{
312
-		$this->postCode = $postCode;
313
-
314
-		return $this;
315
-	}
316
-
317
-	/**
318
-	 * @return string|null
319
-	 */
320
-	public function getLandline():? string
321
-	{
322
-		return $this->landline;
323
-	}
324
-
325
-	/**
326
-	 * @param string|null $landline
327
-	 * @return AddressInterface
328
-	 */
329
-	public function setLandline(?string $landline): AddressInterface
330
-	{
331
-		$this->landline = $landline;
332
-
333
-		return $this;
334
-	}
335
-
336
-	/**
337
-	 * @return string|null
338
-	 */
339
-	public function getAddressLine1():? string
340
-	{
341
-		return $this->addressLine1;
342
-	}
343
-
344
-	/**
345
-	 * @param string|null $addressLine1
346
-	 * @return AddressInterface
347
-	 */
348
-	public function setAddressLine1(?string $addressLine1): AddressInterface
349
-	{
350
-		$this->addressLine1 = $addressLine1;
351
-
352
-		return $this;
353
-	}
354
-
355
-	/**
356
-	 * @return string|null
357
-	 */
358
-	public function getAddressLine2():? string
359
-	{
360
-		return $this->addressLine2;
361
-	}
362
-
363
-	/**
364
-	 * @param string|null $addressLine2
365
-	 * @return AddressInterface
366
-	 */
367
-	public function setAddressLine2(?string $addressLine2): AddressInterface
368
-	{
369
-		$this->addressLine2 = $addressLine2;
370
-
371
-		return $this;
372
-	}
373
-
374
-	/**
375
-	 * Get address State
376
-	 *
377
-	 * @return  string|null
378
-	 */
379
-	public function getState(): ?string
380
-	{
381
-		return $this->state;
382
-	}
383
-
384
-	/**
385
-	 * Set address State
386
-	 *
387
-	 * @param  string|null  $state  Address State
388
-	 *
389
-	 * @return  AddressInterface
390
-	 */
391
-	public function setState(?string $state): AddressInterface
392
-	{
393
-		$this->state = $state;
394
-
395
-		return $this;
396
-	}
273
+    {
274
+        $this->regionId = $regionId;
275
+
276
+        return $this;
277
+    }
278
+
279
+    /**
280
+     * @return string|null
281
+     */
282
+    public function getRegionName():? string
283
+    {
284
+        return $this->regionName;
285
+    }
286
+
287
+    /**
288
+     * @param string|null $regionName
289
+     * @return AddressInterface
290
+     */
291
+    public function setRegionName(?string $regionName): AddressInterface
292
+    {
293
+        $this->regionName = $regionName;
294
+
295
+        return $this;
296
+    }
297
+
298
+    /**
299
+     * @return string|null
300
+     */
301
+    public function getPostCode():? string
302
+    {
303
+        return $this->postCode;
304
+    }
305
+
306
+    /**
307
+     * @param string|null $postCode
308
+     * @return AddressInterface
309
+     */
310
+    public function setPostCode(?string $postCode): AddressInterface
311
+    {
312
+        $this->postCode = $postCode;
313
+
314
+        return $this;
315
+    }
316
+
317
+    /**
318
+     * @return string|null
319
+     */
320
+    public function getLandline():? string
321
+    {
322
+        return $this->landline;
323
+    }
324
+
325
+    /**
326
+     * @param string|null $landline
327
+     * @return AddressInterface
328
+     */
329
+    public function setLandline(?string $landline): AddressInterface
330
+    {
331
+        $this->landline = $landline;
332
+
333
+        return $this;
334
+    }
335
+
336
+    /**
337
+     * @return string|null
338
+     */
339
+    public function getAddressLine1():? string
340
+    {
341
+        return $this->addressLine1;
342
+    }
343
+
344
+    /**
345
+     * @param string|null $addressLine1
346
+     * @return AddressInterface
347
+     */
348
+    public function setAddressLine1(?string $addressLine1): AddressInterface
349
+    {
350
+        $this->addressLine1 = $addressLine1;
351
+
352
+        return $this;
353
+    }
354
+
355
+    /**
356
+     * @return string|null
357
+     */
358
+    public function getAddressLine2():? string
359
+    {
360
+        return $this->addressLine2;
361
+    }
362
+
363
+    /**
364
+     * @param string|null $addressLine2
365
+     * @return AddressInterface
366
+     */
367
+    public function setAddressLine2(?string $addressLine2): AddressInterface
368
+    {
369
+        $this->addressLine2 = $addressLine2;
370
+
371
+        return $this;
372
+    }
373
+
374
+    /**
375
+     * Get address State
376
+     *
377
+     * @return  string|null
378
+     */
379
+    public function getState(): ?string
380
+    {
381
+        return $this->state;
382
+    }
383
+
384
+    /**
385
+     * Set address State
386
+     *
387
+     * @param  string|null  $state  Address State
388
+     *
389
+     * @return  AddressInterface
390
+     */
391
+    public function setState(?string $state): AddressInterface
392
+    {
393
+        $this->state = $state;
394
+
395
+        return $this;
396
+    }
397 397
 }
Please login to merge, or discard this patch.
src/Customer/CustomerClient.php 2 patches
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -23,15 +23,15 @@  discard block
 block discarded – undo
23 23
     protected $options = [];
24 24
 
25 25
     /**
26
-	 * CheckoutClientInterface constructor.
27
-	 * @param ContextInterface $context
26
+     * CheckoutClientInterface constructor.
27
+     * @param ContextInterface $context
28 28
      * @param array $options
29 29
      */
30 30
     public function __construct(ContextInterface $context, ?array $options = [])
31
-	{
32
-		$this->context = $context;
31
+    {
32
+        $this->context = $context;
33 33
         $this->options = $options;
34
-	}
34
+    }
35 35
 
36 36
     /**
37 37
      * @param $customer
@@ -83,9 +83,9 @@  discard block
 block discarded – undo
83 83
     }
84 84
 
85 85
     public function getLastResponse(): ResponseInterface
86
-	{
87
-		return $this->lastResponse;
88
-	}
86
+    {
87
+        return $this->lastResponse;
88
+    }
89 89
 
90 90
     /**
91 91
      * @param ResponseInterface $response
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -146,7 +146,7 @@
 block discarded – undo
146 146
     /**
147 147
      * @return AccessToken
148 148
      */
149
-    public function getToken():? AccessToken
149
+    public function getToken(): ? AccessToken
150 150
     {
151 151
         return $this->token;
152 152
     }
Please login to merge, or discard this patch.
src/Customer/CustomerClientInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
      * @param CustomerInterface $customer
13 13
      * @return CustomerInterface
14 14
      */
15
-    public function create(CustomerInterface $customer):? CustomerInterface;
15
+    public function create(CustomerInterface $customer): ? CustomerInterface;
16 16
 
17 17
     /**
18 18
      * @param CustomerInterface $customer
Please login to merge, or discard this patch.
src/Customer/PaymentInstrument/PaymentInstrument.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
      *
88 88
      * @return  string
89 89
      */
90
-    public function getToken():? string
90
+    public function getToken(): ? string
91 91
     {
92 92
         return $this->token;
93 93
     }
@@ -111,7 +111,7 @@  discard block
 block discarded – undo
111 111
      *
112 112
      * @return  bool
113 113
      */
114
-    public function getActive():? bool
114
+    public function getActive(): ? bool
115 115
     {
116 116
         return $this->active;
117 117
     }
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
      *
144 144
      * @return  string
145 145
      */
146
-    public function getType():? string
146
+    public function getType(): ? string
147 147
     {
148 148
         return $this->type;
149 149
     }
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
      * @see http://docs.sumup.com/rest-api/checkouts-api/#customers-payment-instruments-post
173 173
      * @return array
174 174
      */
175
-    public function getCard():? array
175
+    public function getCard(): ? array
176 176
     {
177 177
         return [
178 178
             'last_4_digits' => $this->getLast4Digits(),
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
      *
186 186
      * @return  string
187 187
      */
188
-    public function getLast4Digits():? string
188
+    public function getLast4Digits(): ? string
189 189
     {
190 190
         return $this->last4Digits;
191 191
     }
@@ -209,7 +209,7 @@  discard block
 block discarded – undo
209 209
      *
210 210
      * @return  string
211 211
      */
212
-    public function getCardType():? string
212
+    public function getCardType(): ? string
213 213
     {
214 214
         return $this->cardSchema;
215 215
     }
Please login to merge, or discard this patch.
src/Customer/PaymentInstrument/PaymentInstrumentClient.php 2 patches
Indentation   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -55,10 +55,10 @@  discard block
 block discarded – undo
55 55
         return null;
56 56
     }
57 57
 
58
-	/**
58
+    /**
59 59
      * Retrieve a paymentInstrument from server and fill the $paymentInstrument Object with response.
60
-	 *
61
-	 */
60
+     *
61
+     */
62 62
     public function get(): array
63 63
     {
64 64
         $response = [];
@@ -70,20 +70,20 @@  discard block
 block discarded – undo
70 70
         };
71 71
 
72 72
         return $response;
73
-	}
73
+    }
74 74
 
75
-	/**
75
+    /**
76 76
      * Delete an paymentInstrument from server.
77
-	 *
77
+     *
78 78
      * @param PaymentInstrumentInterface $paymentInstrument
79 79
      * @return bool
80
-	 */
80
+     */
81 81
     public function disable(PaymentInstrumentInterface $paymentInstrument):?bool
82 82
     {
83 83
         $uri = $this->getEndPoint().'/'.$paymentInstrument->getToken();
84 84
 
85 85
         return $this->request('delete', $paymentInstrument, $uri);
86
-	}
86
+    }
87 87
 
88 88
     /**
89 89
      * @return string
@@ -93,14 +93,14 @@  discard block
 block discarded – undo
93 93
         return 'customers/'.$this->customer->getCustomerId().'/payment-instruments';
94 94
     }
95 95
 
96
-	/**
97
-	 * Return last response of client
98
-	 * @return ResponseInterface
99
-	 */
96
+    /**
97
+     * Return last response of client
98
+     * @return ResponseInterface
99
+     */
100 100
     public function getLastResponse(): ResponseInterface
101
-	{
101
+    {
102 102
         return $this->lastResponse;
103
-	}
103
+    }
104 104
 
105 105
     /**
106 106
      * @param ResponseInterface $response
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -78,9 +78,9 @@  discard block
 block discarded – undo
78 78
      * @param PaymentInstrumentInterface $paymentInstrument
79 79
      * @return bool
80 80
 	 */
81
-    public function disable(PaymentInstrumentInterface $paymentInstrument):?bool
81
+    public function disable(PaymentInstrumentInterface $paymentInstrument): ?bool
82 82
     {
83
-        $uri = $this->getEndPoint().'/'.$paymentInstrument->getToken();
83
+        $uri = $this->getEndPoint() . '/' . $paymentInstrument->getToken();
84 84
 
85 85
         return $this->request('delete', $paymentInstrument, $uri);
86 86
 	}
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
      */
91 91
     public function getEndPoint(): string
92 92
     {
93
-        return 'customers/'.$this->customer->getCustomerId().'/payment-instruments';
93
+        return 'customers/' . $this->customer->getCustomerId() . '/payment-instruments';
94 94
     }
95 95
 
96 96
 	/**
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
     /**
134 134
      * @return AccessToken
135 135
      */
136
-    public function getToken():? AccessToken
136
+    public function getToken(): ? AccessToken
137 137
     {
138 138
         return $this->token;
139 139
     }
Please login to merge, or discard this patch.
src/Customer/PaymentInstrument/PaymentInstrumentInterface.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
     /**
14 14
      * @return null|string
15 15
      */
16
-    public function getToken():? string;
16
+    public function getToken(): ? string;
17 17
 
18 18
     /**
19 19
      * @param null|string $token
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
     /**
36 36
      * @return null|string
37 37
      */
38
-    public function getType():? string;
38
+    public function getType(): ? string;
39 39
 
40 40
     /**
41 41
      * @param null|string $type
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
     /**
47 47
      * @return array|null
48 48
      */
49
-    public function getCard():? array;
49
+    public function getCard(): ? array;
50 50
 
51 51
     /**
52 52
      * @param array|null $data
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
     /**
58 58
      * @return null|string
59 59
      */
60
-    public function getLast4Digits():? string;
60
+    public function getLast4Digits(): ? string;
61 61
 
62 62
     /**
63 63
      * @param null|string $digits
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
     /**
69 69
      * @return null|string
70 70
      */
71
-    public function getCardType():? string;
71
+    public function getCardType(): ? string;
72 72
 
73 73
     /**
74 74
      * @param null|string $schema
Please login to merge, or discard this patch.
src/Customer/Customer.php 1 patch
Indentation   +121 added lines, -121 removed lines patch added patch discarded remove patch
@@ -4,132 +4,132 @@
 block discarded – undo
4 4
 
5 5
 class Customer implements CustomerInterface
6 6
 {
7
-	/**
8
-	 * Customer SumUp ID
9
-	 *
10
-	 * @var string
11
-	 */
12
-	protected $customerId;
13
-
14
-	/**
15
-	 * Customer Name
16
-	 *
17
-	 * @var string
18
-	 */
19
-	protected $name;
20
-
21
-	/**
22
-	 * Customer phone
23
-	 *
24
-	 * @var string
25
-	 */
26
-	protected $phone;
27
-
28
-	/**
29
-	 * Cusomter address
30
-	 *
31
-	 * @var AddressInterface
32
-	 */
33
-	protected $address;
7
+    /**
8
+     * Customer SumUp ID
9
+     *
10
+     * @var string
11
+     */
12
+    protected $customerId;
13
+
14
+    /**
15
+     * Customer Name
16
+     *
17
+     * @var string
18
+     */
19
+    protected $name;
20
+
21
+    /**
22
+     * Customer phone
23
+     *
24
+     * @var string
25
+     */
26
+    protected $phone;
27
+
28
+    /**
29
+     * Cusomter address
30
+     *
31
+     * @var AddressInterface
32
+     */
33
+    protected $address;
34 34
 
35 35
     public function __construct(?array $data = [])
36
-	{
37
-		$this->setCustomerId($data['customer_id']??null);
38
-		$personal_details = $data['personal_details']??$data;
39
-		$this->setName($personal_details['name']??null);
40
-		$this->setPhone($personal_details['phone']??null);
41
-		$this->setAddress(new Address($personal_details['address']??null));
42
-	}
43
-
44
-	/**
45
-	 * Get customer SumUp ID
46
-	 *
47
-	 * @return  string
48
-	 */
49
-	public function getCustomerId(): ?string
50
-	{
51
-		return $this->customerId;
52
-	}
53
-
54
-	/**
55
-	 * Set customer SumUp ID
56
-	 *
57
-	 * @param  string $customerId Customer SumUp ID
58
-	 * @return CustomerInterface
59
-	 */
60
-	public function setCustomerId(?string $customerId): CustomerInterface
61
-	{
62
-		$this->customerId = $customerId;
63
-
64
-		return $this;
65
-	}
66
-
67
-	/**
68
-	 * Get customer Name
69
-	 *
70
-	 * @return  string
71
-	 */
72
-	public function getName(): ?string
73
-	{
74
-		return $this->name;
75
-	}
76
-
77
-	/**
78
-	 * Set customer Name
79
-	 *
36
+    {
37
+        $this->setCustomerId($data['customer_id']??null);
38
+        $personal_details = $data['personal_details']??$data;
39
+        $this->setName($personal_details['name']??null);
40
+        $this->setPhone($personal_details['phone']??null);
41
+        $this->setAddress(new Address($personal_details['address']??null));
42
+    }
43
+
44
+    /**
45
+     * Get customer SumUp ID
46
+     *
47
+     * @return  string
48
+     */
49
+    public function getCustomerId(): ?string
50
+    {
51
+        return $this->customerId;
52
+    }
53
+
54
+    /**
55
+     * Set customer SumUp ID
56
+     *
57
+     * @param  string $customerId Customer SumUp ID
58
+     * @return CustomerInterface
59
+     */
60
+    public function setCustomerId(?string $customerId): CustomerInterface
61
+    {
62
+        $this->customerId = $customerId;
63
+
64
+        return $this;
65
+    }
66
+
67
+    /**
68
+     * Get customer Name
69
+     *
70
+     * @return  string
71
+     */
72
+    public function getName(): ?string
73
+    {
74
+        return $this->name;
75
+    }
76
+
77
+    /**
78
+     * Set customer Name
79
+     *
80 80
      * @param  string $name Customer Name
81 81
      * @return Customer|CustomerInterface
82
-	 */
83
-	public function setName(?string $name): CustomerInterface
84
-	{
85
-		$this->name = $name;
86
-
87
-		return $this;
88
-	}
89
-
90
-	/**
91
-	 * Get customer phone
92
-	 *
93
-	 * @return  string
94
-	 */
95
-	public function getPhone(): ?string
96
-	{
97
-		return $this->phone;
98
-	}
99
-
100
-	/**
101
-	 * Set customer phone
102
-	 *
82
+     */
83
+    public function setName(?string $name): CustomerInterface
84
+    {
85
+        $this->name = $name;
86
+
87
+        return $this;
88
+    }
89
+
90
+    /**
91
+     * Get customer phone
92
+     *
93
+     * @return  string
94
+     */
95
+    public function getPhone(): ?string
96
+    {
97
+        return $this->phone;
98
+    }
99
+
100
+    /**
101
+     * Set customer phone
102
+     *
103 103
      * @param  string $phone Customer phone
104 104
      * @return Customer|CustomerInterface
105
-	 */
106
-	public function setPhone(?string $phone): CustomerInterface
107
-	{
108
-		$this->phone = $phone;
109
-
110
-		return $this;
111
-	}
112
-
113
-	/**
114
-	 * Get cusomter address
115
-	 *
116
-	 * @return  AddressInterface
117
-	 */
118
-	public function getAddress(): AddressInterface
119
-	{
120
-		return $this->address;
121
-	}
122
-
123
-	/**
124
-	 * Set cusomter address
125
-	 *
126
-	 * @param AddressInterface $address
127
-	 * @return Customer|CustomerInterface
128
-	 */
129
-	public function setAddress(AddressInterface $address): CustomerInterface
130
-	{
131
-		$this->address = $address;
132
-		return $this;
133
-	}
105
+     */
106
+    public function setPhone(?string $phone): CustomerInterface
107
+    {
108
+        $this->phone = $phone;
109
+
110
+        return $this;
111
+    }
112
+
113
+    /**
114
+     * Get cusomter address
115
+     *
116
+     * @return  AddressInterface
117
+     */
118
+    public function getAddress(): AddressInterface
119
+    {
120
+        return $this->address;
121
+    }
122
+
123
+    /**
124
+     * Set cusomter address
125
+     *
126
+     * @param AddressInterface $address
127
+     * @return Customer|CustomerInterface
128
+     */
129
+    public function setAddress(AddressInterface $address): CustomerInterface
130
+    {
131
+        $this->address = $address;
132
+        return $this;
133
+    }
134 134
 
135 135
 }
Please login to merge, or discard this patch.
src/Checkout/CheckoutClient.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
     static function getCompleteUrl(CheckoutInterface $checkout): string
124 124
     {
125 125
         if ($checkout->getId()) {
126
-            return SumUp::getEntrypoint().$checkout->getId();
126
+            return SumUp::getEntrypoint() . $checkout->getId();
127 127
         }
128 128
 
129 129
         return '';
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
      * @throws BadResponseException
135 135
      * @throws ConnectException
136 136
      */
137
-    public function create(CheckoutInterface $checkout, AccessToken $accessToken = null):? CheckoutInterface
137
+    public function create(CheckoutInterface $checkout, AccessToken $accessToken = null): ? CheckoutInterface
138 138
     {
139 139
         return $this->request('post', $checkout) ? $checkout : null;
140 140
     }
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
      * @param string|null $endpoint
146 146
      * @return bool|null
147 147
      */
148
-    public function request(string $action, $checkout, string $endpoint = null):? bool
148
+    public function request(string $action, $checkout, string $endpoint = null): ? bool
149 149
     {
150 150
         if (!$checkout->isValid()) {
151 151
             throw new InvalidCheckoutException($checkout);
@@ -159,7 +159,7 @@  discard block
 block discarded – undo
159 159
      * @throws BadResponseException
160 160
      * @throws ConnectException
161 161
      */
162
-    public function complete(CheckoutInterface $checkout, AccessToken $accessToken = null):? CheckoutInterface
162
+    public function complete(CheckoutInterface $checkout, AccessToken $accessToken = null): ? CheckoutInterface
163 163
     {
164 164
         return $this->request('put', $checkout) ? $checkout : null;
165 165
     }
@@ -219,7 +219,7 @@  discard block
 block discarded – undo
219 219
     /**
220 220
      * @return AccessToken
221 221
      */
222
-    public function getToken():? AccessToken
222
+    public function getToken(): ? AccessToken
223 223
     {
224 224
         return $this->currentToken;
225 225
     }
Please login to merge, or discard this patch.