From 5e950873e45db359baec6996e7dbf3e3ccda7030 Mon Sep 17 00:00:00 2001 From: Leevi Graham Date: Thu, 6 Nov 2014 17:19:42 +1100 Subject: [PATCH] Update auth-server-password.md --- auth-server-password.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/auth-server-password.md b/auth-server-password.md index 2599473d..693445b6 100755 --- a/auth-server-password.md +++ b/auth-server-password.md @@ -22,6 +22,8 @@ $passwordGrant = new \League\OAuth2\Server\Grant\PasswordGrant(); $passwordGrant->setVerifyCredentialsCallback(function ($username, $password) { // implement logic here to validate a username and password, return an ID if valid, otherwise return false }); + +$server->addGrantType($passwordGrant); ~~~ @@ -59,4 +61,4 @@ $router->post('/access_token', function (Request $request) use ($server) { } }); -~~~ \ No newline at end of file +~~~