diff --git a/lib/stripe.ex b/lib/stripe.ex index 88e3be8..2bf2541 100644 --- a/lib/stripe.ex +++ b/lib/stripe.ex @@ -73,7 +73,8 @@ defmodule Stripe do Returns binary """ def key do - System.get_env "STRIPE_SECRET_KEY" + Application.get_env(:stripe, :secret_key) || + System.get_env "STRIPE_SECRET_KEY" end defp url_encode_keyvalue({k, v}) do