Skip to content

Commit

Permalink
Merge branch 'bc-checkout' into staging
Browse files Browse the repository at this point in the history
  • Loading branch information
macifell committed May 21, 2024
2 parents 436b6e1 + 3975318 commit d32e4ec
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/recognizer_web/router.ex
Original file line number Diff line number Diff line change
Expand Up @@ -33,17 +33,17 @@ defmodule RecognizerWeb.Router do
plug :add_bc_to_session
end

defp add_bc_to_session(%{query_params: %{"bc" => "true"}} = conn, _opts) do
defp add_bc_to_session(%{query_params: %{"bc" => "true", "checkout" => "true"}} = conn, _opts) do
if Recognizer.BigCommerce.enabled?() do
put_session(conn, :bc, true)
put_session(conn, :bc_checkout, true)
else
conn
end
end

defp add_bc_to_session(%{query_params: %{"bc" => "true", "checkout" => "true"}} = conn, _opts) do
defp add_bc_to_session(%{query_params: %{"bc" => "true"}} = conn, _opts) do
if Recognizer.BigCommerce.enabled?() do
put_session(conn, :bc_checkout, true)
put_session(conn, :bc, true)
else
conn
end
Expand Down

0 comments on commit d32e4ec

Please sign in to comment.