lib/pagseguro/checkout.rb in pagseguro_next-0.3.0 vs lib/pagseguro/checkout.rb in pagseguro_next-0.4.0
- old
+ new
@@ -1,9 +1,9 @@
module PagSeguro
class Checkout < Base
def create(params)
- params = build_request(params).to_xml
+ params = build_request(params).to_xml(encoding: "UTF-8")
response = api.post "/v2/checkout", params do |conn|
conn.headers[:content_type] = FORMATS[:xml]
conn.headers[:accept] = FORMATS[:xml]
end
@@ -25,10 +25,10 @@
ip params[:remote_ip]
end if params.key?(:remote_ip)
items do
item do
id params[:id]
- description params[:description]
+ description { cdata(params[:description]) }
amount format("%.2f", params[:amount].to_f)
quantity 1
end
end
shipping do