@@ -51,7 +51,7 @@ |
||
| 51 | 51 | */ |
| 52 | 52 | public function updateAttribute() |
| 53 | 53 | { |
| 54 | - foreach($this->attributes as $attribute) { |
|
| 54 | + foreach ($this->attributes as $attribute) { |
|
| 55 | 55 | if ($this->owner->{$attribute} === null) { |
| 56 | 56 | $this->owner->{$attribute} = []; |
| 57 | 57 | } |
@@ -32,8 +32,8 @@ |
||
| 32 | 32 | <div class="row"> |
| 33 | 33 | <div class="col-md-push-3 col-md-6 col-sm-push-2 col-sm-8 col-xs-12 white-panel"> |
| 34 | 34 | <div class="alert" role="alert"> |
| 35 | - <h4 class="alert-heading"><?php echo ($type ? : 'Unkown error'); ?></h4> |
|
| 36 | - <p><?php echo ($description ? : 'Please check your request'); ?></p> |
|
| 35 | + <h4 class="alert-heading"><?php echo ($type ?: 'Unkown error'); ?></h4> |
|
| 36 | + <p><?php echo ($description ?: 'Please check your request'); ?></p> |
|
| 37 | 37 | </div> |
| 38 | 38 | </div> |
| 39 | 39 | </div> |
@@ -35,9 +35,9 @@ |
||
| 35 | 35 | <div class="row"> |
| 36 | 36 | <div class="col-md-push-3 col-md-6 col-sm-push-2 col-sm-8 col-xs-12 white-panel"> |
| 37 | 37 | <?php echo Html::beginForm(); ?> |
| 38 | - <?php if(empty($requestedScopes) === false) : ?> |
|
| 38 | + <?php if (empty($requestedScopes) === false) : ?> |
|
| 39 | 39 | <ul class="list-group"> |
| 40 | - <?php foreach($requestedScopes as $scope): ?> |
|
| 40 | + <?php foreach ($requestedScopes as $scope): ?> |
|
| 41 | 41 | <li class="list-group-item"> |
| 42 | 42 | <h4 class="list-group-item-heading"><?php echo $scope['id']; ?></h4> |
| 43 | 43 | <p class="list-group-item-text"> |
@@ -27,7 +27,7 @@ |
||
| 27 | 27 | </head> |
| 28 | 28 | <body> |
| 29 | 29 | <?php $this->beginBody(); ?> |
| 30 | - <?php echo $content;?> |
|
| 30 | + <?php echo $content; ?> |
|
| 31 | 31 | <?php $this->endBody(); ?> |
| 32 | 32 | </body> |
| 33 | 33 | |
@@ -163,7 +163,7 @@ |
||
| 163 | 163 | /** |
| 164 | 164 | * @var int duration of login time for multiple authorize calls |
| 165 | 165 | */ |
| 166 | - public $loginDuration = 60 * 60 * 24 * 30; |
|
| 166 | + public $loginDuration = 60*60*24*30; |
|
| 167 | 167 | /** |
| 168 | 168 | * @inheritdoc |
| 169 | 169 | */ |
@@ -201,7 +201,7 @@ |
||
| 201 | 201 | $requestedScopes = []; |
| 202 | 202 | if (empty($additionalScopes) === false) { |
| 203 | 203 | $additionalScopes = explode(' ', $additionalScopes); |
| 204 | - foreach($additionalScopes as $scope) { |
|
| 204 | + foreach ($additionalScopes as $scope) { |
|
| 205 | 205 | $dbScope = Scope::findOne($scope); |
| 206 | 206 | if ($dbScope !== null) { |
| 207 | 207 | $requestedScopes[] = [ |
@@ -75,10 +75,10 @@ discard block |
||
| 75 | 75 | $client->grantTypes = empty($this->grantTypes) ? null : explode(',', $this->grantTypes); |
| 76 | 76 | if ($client->save() === true) { |
| 77 | 77 | $this->stdout('Client created :'."\n"); |
| 78 | - $this->stdout(' - id: ' . $client->id . "\n"); |
|
| 79 | - $this->stdout(' - secret: ' . $client->secret . "\n"); |
|
| 80 | - $this->stdout(' - name: ' . $client->name . "\n"); |
|
| 81 | - $this->stdout(' - redirectUri: ' . $client->redirectUri . "\n"); |
|
| 78 | + $this->stdout(' - id: '.$client->id."\n"); |
|
| 79 | + $this->stdout(' - secret: '.$client->secret."\n"); |
|
| 80 | + $this->stdout(' - name: '.$client->name."\n"); |
|
| 81 | + $this->stdout(' - redirectUri: '.$client->redirectUri."\n"); |
|
| 82 | 82 | return Controller::EXIT_CODE_NORMAL; |
| 83 | 83 | } else { |
| 84 | 84 | $this->stdout('Client cannot be created.'."\n"); |
@@ -97,11 +97,11 @@ discard block |
||
| 97 | 97 | $client->scopes = empty($this->scope) ? null : explode(',', $this->scopes); |
| 98 | 98 | $client->grantTypes = empty($this->grantTypes) ? null : explode(',', $this->grantTypes); |
| 99 | 99 | if ($client->save() === true) { |
| 100 | - $this->stdout('Client updated :' . "\n"); |
|
| 101 | - $this->stdout(' - id: ' . $client->id . "\n"); |
|
| 102 | - $this->stdout(' - secret: ' . $client->secret . "\n"); |
|
| 103 | - $this->stdout(' - name: ' . $client->name . "\n"); |
|
| 104 | - $this->stdout(' - redirectUri: ' . $client->redirectUri . "\n"); |
|
| 100 | + $this->stdout('Client updated :'."\n"); |
|
| 101 | + $this->stdout(' - id: '.$client->id."\n"); |
|
| 102 | + $this->stdout(' - secret: '.$client->secret."\n"); |
|
| 103 | + $this->stdout(' - name: '.$client->name."\n"); |
|
| 104 | + $this->stdout(' - redirectUri: '.$client->redirectUri."\n"); |
|
| 105 | 105 | return Controller::EXIT_CODE_NORMAL; |
| 106 | 106 | } else { |
| 107 | 107 | $this->stdout('Client cannot be updated.'."\n"); |
@@ -121,7 +121,7 @@ discard block |
||
| 121 | 121 | */ |
| 122 | 122 | protected function getRandomString($length = 40) |
| 123 | 123 | { |
| 124 | - $bytes = (int) $length/2; |
|
| 124 | + $bytes = (int)$length/2; |
|
| 125 | 125 | return bin2hex(openssl_random_pseudo_bytes($bytes)); |
| 126 | 126 | } |
| 127 | 127 | } |
@@ -44,7 +44,7 @@ |
||
| 44 | 44 | */ |
| 45 | 45 | protected function getAuthCodeKey($aid) |
| 46 | 46 | { |
| 47 | - return $this->namespace . ':' . $aid; |
|
| 47 | + return $this->namespace.':'.$aid; |
|
| 48 | 48 | } |
| 49 | 49 | |
| 50 | 50 | /** |
@@ -44,7 +44,7 @@ |
||
| 44 | 44 | */ |
| 45 | 45 | protected function getAuthCodeKey($aid) |
| 46 | 46 | { |
| 47 | - return $this->namespace . ':' . $aid; |
|
| 47 | + return $this->namespace.':'.$aid; |
|
| 48 | 48 | } |
| 49 | 49 | |
| 50 | 50 | /** |