Merge pull request #26 from patrickober/master

fix for issue #24
This commit is contained in:
Denis CLAVIER 2019-03-06 23:04:39 +01:00 committed by GitHub
commit 033a11da5f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -24,7 +24,7 @@ $resp = array("error" => "Unknown error", "message" => "An unknown error has occ
// get information on user associated to the token // get information on user associated to the token
$info_oauth = $server->getAccessTokenData(OAuth2\Request::createFromGlobals()); $info_oauth = $server->getAccessTokenData(OAuth2\Request::createFromGlobals());
$user = $info_oauth["user_id"]; $user = $info_oauth["user_id"];
$assoc_id = $info_oauth["assoc_id"]; $assoc_id = intval($info_oauth["assoc_id"]);
// Open a LDAP connection // Open a LDAP connection
$ldap = new LDAP($hostname,$port,$ldap_version); $ldap = new LDAP($hostname,$port,$ldap_version);
@ -46,4 +46,4 @@ catch (Exception $e)
} }
// send data or error message in JSON format // send data or error message in JSON format
echo json_encode($resp); echo json_encode($resp);