The in-app billing order for my app is automatically canceled.
I have “google.iap.billing.v2”
Even if you execute “store.finishTransaction( event.transaction )”, the order is not approved.
Anyone know a solution?
Google play will automatically process the refund in 3 days.
I don’t know how to authorize a purchase.
here is my code
local function transactionCallback( event )
if (event.name == "init" ) and (store.target == "google") then
if ( event.isError ) then
-- alert
end
elseif (event.name == "storeTransaction" ) then
if event.transaction.state == "purchased" or
event.transaction.state == "restored" or
event.transaction.state == "restoreCompleted" then
elseif event.transaction.state == "refunded" then
-- refunded
elseif event.transaction.state == "cancelled" then
print( "Transaction cancelled by user." )
elseif event.transaction.state == "failed" then
print( "Transaction failed." )
else
print( "Unknown event" )
end
--
store.finishTransaction( event.transaction )
end
print("=== finish transactionCallback ===")
end