diff --git a/Spotify4Unity/Assets/Spotify4Unity/Core/Managed Authentification/PKCE/PKCE_Authentification.cs b/Spotify4Unity/Assets/Spotify4Unity/Core/Managed Authentification/PKCE/PKCE_Authentification.cs index d0d7d91..185ab26 100644 --- a/Spotify4Unity/Assets/Spotify4Unity/Core/Managed Authentification/PKCE/PKCE_Authentification.cs +++ b/Spotify4Unity/Assets/Spotify4Unity/Core/Managed Authentification/PKCE/PKCE_Authentification.cs @@ -250,6 +250,10 @@ private PKCETokenResponse LoadPKCEToken() // Load token from File if (!string.IsNullOrEmpty(PKCEConfig.TokenPath)) { + if (!File.Exists(PKCEConfig.TokenPath)) + { + return null; + } string previousToken = File.ReadAllText(PKCEConfig.TokenPath); if (string.IsNullOrEmpty(previousToken)) {