json stringify and trim recommended currency

This commit is contained in:
Henry Oswald 2017-03-14 17:53:48 +00:00
parent 1ce48e971a
commit 085cc7a0b2

View file

@ -4,11 +4,11 @@ block scripts
script(src="https://js.recurly.com/v3/recurly.js") script(src="https://js.recurly.com/v3/recurly.js")
script(type='text/javascript'). script(type='text/javascript').
window.recomendedCurrency = '#{currency}'
window.countryCode = '#{countryCode}' window.countryCode = '#{countryCode}'
window.plan_code = '#{plan_code}' window.plan_code = '#{plan_code}'
window.recurlyApiKey = "!{settings.apis.recurly.publicKey}" window.recurlyApiKey = "!{settings.apis.recurly.publicKey}"
window.couponCode = "#{couponCode}" window.couponCode = !{JSON.stringify(couponCode)}
window.recomendedCurrency = !{JSON.stringify(currency.slice(0,3))}
block content block content
.content.content-alt .content.content-alt