Completed
Pull Request — master (#184)
by
unknown
06:02
created
src/Dropbox/Authentication/DropboxAuthHelper.php 1 patch
Braces   +6 added lines, -4 removed lines patch added patch discarded remove patch
@@ -176,8 +176,9 @@  discard block
 block discarded – undo
176 176
         }
177 177
 
178 178
         // Adding the token access type
179
-        if ($this->accessTokenType != null && !array_key_exists('token_access_type', $params))
180
-            $params['token_access_type'] = $this->accessTokenType;
179
+        if ($this->accessTokenType != null && !array_key_exists('token_access_type', $params)) {
180
+                    $params['token_access_type'] = $this->accessTokenType;
181
+        }
181 182
 
182 183
         //Get OAuth2 Authorization URL
183 184
         return $this->getOAuth2Client()->getAuthorizationUrl($redirectUri, $state, $params);
@@ -295,8 +296,9 @@  discard block
 block discarded – undo
295 296
      * @param $tokenType string
296 297
      */
297 298
     public function setAccessTokenType($tokenType = self::TOKEN_ACCESS_TYPE_ONLINE) {
298
-        if ($tokenType != self::TOKEN_ACCESS_TYPE_ONLINE && $tokenType != self::TOKEN_ACCESS_TYPE_OFFLINE)
299
-            throw new \InvalidArgumentException("TokenType parameter must be either DropboxAuthHelper::TOKEN_ACCESS_TYPE_ONLINE or DropboxAuthHelper::TOKEN_ACCESS_TYPE_OFFLINE");
299
+        if ($tokenType != self::TOKEN_ACCESS_TYPE_ONLINE && $tokenType != self::TOKEN_ACCESS_TYPE_OFFLINE) {
300
+                    throw new \InvalidArgumentException("TokenType parameter must be either DropboxAuthHelper::TOKEN_ACCESS_TYPE_ONLINE or DropboxAuthHelper::TOKEN_ACCESS_TYPE_OFFLINE");
301
+        }
300 302
 
301 303
         $this->accessTokenType = $tokenType;
302 304
     }
Please login to merge, or discard this patch.
src/Dropbox/Authentication/OAuth2Client.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -141,8 +141,7 @@
 block discarded – undo
141 141
                 'client_id' => $this->getApp()->getClientId(),
142 142
                 'client_secret' => $this->getApp()->getClientSecret()
143 143
             ];
144
-        }
145
-        else
144
+        } else
146 145
         {
147 146
             //Request Params
148 147
             $params = [
Please login to merge, or discard this patch.