Commit 78ccfa2000f3cb2c06d6e9e5c49269556c94759a
1 parent
373f3710cd
Exists in
master
fixes bug get code uri
Showing 1 changed file with 5 additions and 1 deletions Side-by-side Diff
src/SsoClientLibrary.php
| ... | ... | @@ -51,7 +51,11 @@ |
| 51 | 51 | } |
| 52 | 52 | |
| 53 | 53 | public function ssoCallback() { |
| 54 | - if (isset($_GET['code']) && !empty(($_GET['code']))) { | |
| 54 | + $url = parse_url($this->redirectUri); | |
| 55 | + $code = str_replace($url['path'] . '?code=','',$_SERVER['REQUEST_URI']); | |
| 56 | + $code = explode('&',$code); | |
| 57 | + $code = $code[0] ?? ''; | |
| 58 | + if ($code != '') { | |
| 55 | 59 | $_access_token = ''; |
| 56 | 60 | $_errors = ''; |
| 57 | 61 |