@@ -22,7 +22,7 @@ |
||
| 22 | 22 | return false; |
| 23 | 23 | } |
| 24 | 24 | |
| 25 | - if ($noOfRepo >= 5 && $noOfRepo<= 10) { |
|
| 25 | + if ($noOfRepo >= 5 && $noOfRepo <= 10) { |
|
| 26 | 26 | $evangelistTypeMessage = "Damn It!!! Please make the world better, Oh Ye Prodigal Junior Evangelist"; |
| 27 | 27 | } else if ($noOfRepo >= 11 && $noOfRepo <= 20) { |
| 28 | 28 | $evangelistTypeMessage = "Keep Up The Good Work, I crown you Associate Evangelist"; |
@@ -11,11 +11,11 @@ discard block |
||
| 11 | 11 | * @license <https://opensource.org/license/MIT> MIT |
| 12 | 12 | */ |
| 13 | 13 | |
| 14 | - use Laztopaz\OpenSourceEvangelistStatus\EvangelistStatusRankingInterface; |
|
| 14 | + use Laztopaz\OpenSourceEvangelistStatus\EvangelistStatusRankingInterface; |
|
| 15 | 15 | |
| 16 | 16 | |
| 17 | - class EvangelistStatusRanking implements EvangelistStatusRankingInterface |
|
| 18 | - { |
|
| 17 | + class EvangelistStatusRanking implements EvangelistStatusRankingInterface |
|
| 18 | + { |
|
| 19 | 19 | /** |
| 20 | 20 | * This method ranks GitHub users based on the number of repositories they have |
| 21 | 21 | * @param int $noOfRepo |
@@ -23,16 +23,16 @@ discard block |
||
| 23 | 23 | */ |
| 24 | 24 | public static function determineEvangelistLevel($noOfRepo) |
| 25 | 25 | { |
| 26 | - if ($noOfRepo >= 5 && $noOfRepo<= 10) { |
|
| 27 | - $evangelistTypeMessage = "Damn It!!! Please make the world better, Oh Ye Prodigal Junior Evangelist"; |
|
| 28 | - } else if ($noOfRepo >= 11 && $noOfRepo <= 20) { |
|
| 29 | - $evangelistTypeMessage = "Keep Up The Good Work, I crown you Associate Evangelist"; |
|
| 30 | - } else if ($noOfRepo >= 21) { |
|
| 31 | - $evangelistTypeMessage = "Yeah, I crown you Senior Evangelist. Thanks for making the world a better place"; |
|
| 32 | - } else { |
|
| 33 | - $evangelistTypeMessage = "Fuck Off!!! Please make the world better, Oh Ye Lazy Evangelist"; |
|
| 34 | - } |
|
| 35 | - return $evangelistTypeMessage; |
|
| 26 | + if ($noOfRepo >= 5 && $noOfRepo<= 10) { |
|
| 27 | + $evangelistTypeMessage = "Damn It!!! Please make the world better, Oh Ye Prodigal Junior Evangelist"; |
|
| 28 | + } else if ($noOfRepo >= 11 && $noOfRepo <= 20) { |
|
| 29 | + $evangelistTypeMessage = "Keep Up The Good Work, I crown you Associate Evangelist"; |
|
| 30 | + } else if ($noOfRepo >= 21) { |
|
| 31 | + $evangelistTypeMessage = "Yeah, I crown you Senior Evangelist. Thanks for making the world a better place"; |
|
| 32 | + } else { |
|
| 33 | + $evangelistTypeMessage = "Fuck Off!!! Please make the world better, Oh Ye Lazy Evangelist"; |
|
| 34 | + } |
|
| 35 | + return $evangelistTypeMessage; |
|
| 36 | 36 | } |
| 37 | 37 | |
| 38 | 38 | /** |
@@ -47,4 +47,4 @@ discard block |
||
| 47 | 47 | } |
| 48 | 48 | } |
| 49 | 49 | |
| 50 | - } |
|
| 50 | + } |
|
@@ -18,13 +18,13 @@ |
||
| 18 | 18 | * @param void |
| 19 | 19 | * @return void |
| 20 | 20 | */ |
| 21 | - public static function determineEvangelistLevel($noOfRepositories); |
|
| 21 | + public static function determineEvangelistLevel($noOfRepositories); |
|
| 22 | 22 | |
| 23 | - /** |
|
| 24 | - * This method checkForNullRepos |
|
| 25 | - * @param array $jsonBody |
|
| 26 | - * @return boolean |
|
| 27 | - */ |
|
| 28 | - public static function checkForNullRepos($jsonBody); |
|
| 23 | + /** |
|
| 24 | + * This method checkForNullRepos |
|
| 25 | + * @param array $jsonBody |
|
| 26 | + * @return boolean |
|
| 27 | + */ |
|
| 28 | + public static function checkForNullRepos($jsonBody); |
|
| 29 | 29 | |
| 30 | 30 | } |
@@ -22,6 +22,6 @@ |
||
| 22 | 22 | */ |
| 23 | 23 | public static function NullOfOverflowArgumentException($exception) |
| 24 | 24 | { |
| 25 | - return new static($exception); |
|
| 25 | + return new static($exception); |
|
| 26 | 26 | } |
| 27 | 27 | } |
@@ -22,6 +22,6 @@ |
||
| 22 | 22 | */ |
| 23 | 23 | public static function NullOfOverflowArgumentException($exception) |
| 24 | 24 | { |
| 25 | - return new static($exception); |
|
| 25 | + return new static($exception); |
|
| 26 | 26 | } |
| 27 | 27 | } |
@@ -22,6 +22,6 @@ |
||
| 22 | 22 | */ |
| 23 | 23 | public static function createEvangelistStatusException($message) |
| 24 | 24 | { |
| 25 | - return new static($message); |
|
| 25 | + return new static($message); |
|
| 26 | 26 | } |
| 27 | 27 | } |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | { |
| 36 | 36 | $num_args = (int) func_num_args(); // get number of arguments passed to |
| 37 | 37 | |
| 38 | - if ($num_args == 0 || $num_args > 1) { |
|
| 38 | + if ($num_args == 0 || $num_args > 1) { |
|
| 39 | 39 | throw ArgumentCheckException::NullOfOverflowArgumentException("Argument missing: only one argument is allowed"); |
| 40 | 40 | } |
| 41 | 41 | $this->checkNullUsernameException(); |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | */ |
| 59 | 59 | public function getGitApiData() |
| 60 | 60 | { |
| 61 | - $this->response = $this->guzzleClient->get('https://api.github.com/users/'.$this->username.'?client_id='.$this->clientId .'&client_secret='.$this->clientSecret); |
|
| 61 | + $this->response = $this->guzzleClient->get('https://api.github.com/users/'.$this->username.'?client_id='.$this->clientId.'&client_secret='.$this->clientSecret); |
|
| 62 | 62 | return $this->response->getBody(); |
| 63 | 63 | } |
| 64 | 64 | |