Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sample/Assets/Scripts/SelectAuthMethodScript.cs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ private bool IsPKCESupported()
public void UseDeviceCodeAuth()
{
SampleAppManager.UsePKCE = false;
InitialisePassport();
InitialisePassport(logoutRedirectUri: "https://www.immutable.com");
}

/// <summary>
Expand All @@ -61,7 +61,7 @@ public void UsePKCE()
/// </summary>
/// <param name="redirectUri">(Android, iOS and macOS only) The URL to which auth will redirect the browser after
/// authorisation has been granted by the user</param>
/// <param name="logoutRedirectUri">(Android, iOS and macOS only) The URL to which auth will redirect the browser
/// <param name="logoutRedirectUri">The URL to which auth will redirect the browser
/// after log out is complete</param>
private async void InitialisePassport(string redirectUri = null, string logoutRedirectUri = null)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ internal class InitRequest
{
public string clientId;
public string environment;
public string logoutRedirectUri;
public VersionInfo engineVersion;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public async UniTask Init(string clientId, string environment, string redirectUr
};

string initRequest;
if (redirectUri != null && logoutRedirectUri != null)
if (redirectUri != null)
{
InitRequestWithRedirectUri requestWithRedirectUri = new InitRequestWithRedirectUri()
{
Expand All @@ -89,6 +89,7 @@ public async UniTask Init(string clientId, string environment, string redirectUr
{
clientId = clientId,
environment = environment,
logoutRedirectUri = logoutRedirectUri,
engineVersion = versionInfo
};
initRequest = JsonUtility.ToJson(request);
Expand Down