diff --git a/lib/livebook/zta/cloudflare.ex b/lib/livebook/zta/cloudflare.ex index 6b78c871369..1307e158cdc 100644 --- a/lib/livebook/zta/cloudflare.ex +++ b/lib/livebook/zta/cloudflare.ex @@ -49,7 +49,7 @@ defmodule Livebook.ZTA.Cloudflare do {:ok, token} <- verify_token(encoded_token, keys), :ok <- verify_iss(token, identity.iss), {:ok, user} <- get_user_identity(encoded_token, identity.user_identity) do - for({k, v} <- user, new_k = @fields[k], do: {new_k, v}, into: %{payload: token.fields}) + for({k, v} <- user, new_k = @fields[k], do: {new_k, v}, into: %{payload: user}) else _ -> nil end diff --git a/lib/livebook/zta/livebook_teams.ex b/lib/livebook/zta/livebook_teams.ex index 1adc692db2c..95ae2e0b36f 100644 --- a/lib/livebook/zta/livebook_teams.ex +++ b/lib/livebook/zta/livebook_teams.ex @@ -146,7 +146,7 @@ defmodule Livebook.ZTA.LivebookTeams do name: name, avatar_url: avatar_url, email: email, - payload: %{"access_token" => access_token} + payload: Map.put(payload, "access_token", access_token) } {:ok, metadata}