git.cweiske.de
/
shpub.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Explain that "server" command takes a parameter.
[shpub.git]
/
src
/
shpub
/
Command
/
Connect.php
diff --git
a/src/shpub/Command/Connect.php
b/src/shpub/Command/Connect.php
index e92077779c8abce3eb16d17d13649b1d26a53bec..6ac5ed45d2b54302d8b493c0f0a94094611e1f9d 100644
(file)
--- a/
src/shpub/Command/Connect.php
+++ b/
src/shpub/Command/Connect.php
@@
-177,11
+177,13
@@
class Command_Connect
protected function getBrowserAuthUrl($host, $user, $redirect_uri, $state, $scope)
{
protected function getBrowserAuthUrl($host, $user, $redirect_uri, $state, $scope)
{
+ $sep = strpos($host->endpoints->authorization, '?') === false
+ ? '?' : '&';
return $host->endpoints->authorization
return $host->endpoints->authorization
- .
'?
me=' . urlencode($user)
+ .
$sep . '
me=' . urlencode($user)
. '&client_id=' . urlencode(static::$client_id)
. '&redirect_uri=' . urlencode($redirect_uri)
. '&client_id=' . urlencode(static::$client_id)
. '&redirect_uri=' . urlencode($redirect_uri)
- . '&state=' .
$state
+ . '&state=' .
urlencode($state)
. '&scope=' . urlencode($scope)
. '&response_type=code';
}
. '&scope=' . urlencode($scope)
. '&response_type=code';
}