Skip to content

Commit bc34c1c

Browse files
authored
Apply fixes from StyleCI (#395)
[ci skip] [skip ci] Co-authored-by: KwangSeob Jeong <[email protected]>
1 parent e650cf1 commit bc34c1c

File tree

4 files changed

+14
-15
lines changed

4 files changed

+14
-15
lines changed

src/Configuration/AbstractConfiguration.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ abstract class AbstractConfiguration implements ConfigurationInterface
148148
/** @var int */
149149
protected $timeout;
150150

151-
/** @var boolean */
151+
/** @var bool */
152152
protected $useTokenBasedAuth;
153153

154154
/** @var string */

src/Configuration/ConfigurationInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ public function getTimeout();
176176
public function isTokenBasedAuth();
177177

178178
/**
179-
* Personal Access Token
179+
* Personal Access Token.
180180
*
181181
* @return string
182182
*/

src/JiraClient.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ public function exec($context, $post_data = null, $custom_request = null, $cooki
239239
$curl_http_headers = [
240240
'Accept: */*',
241241
'Content-Type: application/json',
242-
'X-Atlassian-Token: no-check'
242+
'X-Atlassian-Token: no-check',
243243
];
244244

245245
$this->authorization($ch, $curl_http_headers, $cookieFile);
@@ -322,9 +322,9 @@ public function exec($context, $post_data = null, $custom_request = null, $cooki
322322
/**
323323
* Create upload handle.
324324
*
325-
* @param string $url Request URL
326-
* @param string $upload_file Filename
327-
* @param resource $ch CUrl handler
325+
* @param string $url Request URL
326+
* @param string $upload_file Filename
327+
* @param resource $ch CUrl handler
328328
*
329329
* @return resource
330330
*/
@@ -333,7 +333,7 @@ private function createUploadHandle($url, $upload_file, $ch)
333333
$curl_http_headers = [
334334
'Accept: */*',
335335
'Content-Type: multipart/form-data',
336-
'X-Atlassian-Token: no-check'
336+
'X-Atlassian-Token: no-check',
337337
];
338338

339339
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
@@ -513,8 +513,8 @@ protected function authorization($ch, &$curl_http_headers, $cookieFile = null)
513513

514514
// if cookie file not exist, using id/pwd login
515515
if (!file_exists($cookieFile)) {
516-
if ($this->getConfiguration()->isTokenBasedAuth() === true ){
517-
$curl_http_headers[] = 'Authorization: Bearer ' . $this->getConfiguration()->getPeronalAccessToken();
516+
if ($this->getConfiguration()->isTokenBasedAuth() === true) {
517+
$curl_http_headers[] = 'Authorization: Bearer '.$this->getConfiguration()->getPeronalAccessToken();
518518
} else {
519519
$username = $this->getConfiguration()->getJiraUser();
520520
$password = $this->getConfiguration()->getJiraPassword();
@@ -587,7 +587,7 @@ public function download(string $url, string $outDir, string $file, string $cook
587587
$curl_http_header = [
588588
'Accept: */*',
589589
'Content-Type: application/json',
590-
'X-Atlassian-Token: no-check'
590+
'X-Atlassian-Token: no-check',
591591
];
592592

593593
$file = fopen($outDir.DIRECTORY_SEPARATOR.urldecode($file), 'w');

src/Project/ProjectService.php

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -357,9 +357,9 @@ public function deleteProject($projectIdOrKey)
357357

358358
return $ret;
359359
}
360-
361-
/**
362-
* Archive a project only available for premium subscription
360+
361+
/**
362+
* Archive a project only available for premium subscription.
363363
*
364364
* @param string $projectIdOrKey
365365
*
@@ -375,9 +375,8 @@ public function deleteProject($projectIdOrKey)
375375
*/
376376
public function archiveProject($projectIdOrKey)
377377
{
378-
$ret = $this->exec($this->uri . '/' . $projectIdOrKey . '/archive', null, 'PUT');
378+
$ret = $this->exec($this->uri.'/'.$projectIdOrKey.'/archive', null, 'PUT');
379379

380380
return $ret;
381381
}
382-
383382
}

0 commit comments

Comments
 (0)