From dcf4eefc619470e6b28a159ab27a021eaa47d981 Mon Sep 17 00:00:00 2001 From: Jonas Dellinger Date: Sat, 30 Sep 2017 23:24:20 +0200 Subject: [PATCH] Update auth.md --- SpotifyAPI.Docs/docs/SpotifyWebAPI/auth.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/SpotifyAPI.Docs/docs/SpotifyWebAPI/auth.md b/SpotifyAPI.Docs/docs/SpotifyWebAPI/auth.md index 1c570ba1..78e08100 100644 --- a/SpotifyAPI.Docs/docs/SpotifyWebAPI/auth.md +++ b/SpotifyAPI.Docs/docs/SpotifyWebAPI/auth.md @@ -88,15 +88,15 @@ static void Main(string[] args) static void auth_OnResponseReceivedEvent(Token token, string state, string error) { - //stop the http server - auth.StopHttpServer(); - var spotify = new SpotifyWebApiClass() { TokenType = token.TokenType, AccessToken = token.AccessToken }; //We can now make calls with the token object + + //stop the http server + auth.StopHttpServer(); } ``` @@ -138,8 +138,6 @@ static void Main(string[] args) private static void auth_OnResponseReceivedEvent(AutorizationCodeAuthResponse response) { - //Stop the HTTP Server, done. - auth.StopHttpServer(); //NEVER DO THIS! You would need to provide the ClientSecret. //You would need to do it e.g via a PHP-Script. @@ -152,6 +150,9 @@ private static void auth_OnResponseReceivedEvent(AutorizationCodeAuthResponse re }; //With the token object, you can now make API calls + + //Stop the HTTP Server, done. + auth.StopHttpServer(); } ```