public static AnalyticsResult Transaction(string productId, decimal amount, string currency, string receiptPurchaseData, string signature, bool usingIAPService)
{
bool flag = string.IsNullOrEmpty(productId);
if (flag)
{
throw new ArgumentException("Cannot set productId to an empty or null string");
}
bool flag2 = string.IsNullOrEmpty(currency);
if (flag2)
{
throw new ArgumentException("Cannot set currency to an empty or null string");
}
bool flag3 = !Analytics.IsInitialized();
AnalyticsResult result;
if (flag3)
{
result = AnalyticsResult.NotInitialized;
}
else
{
bool flag4 = receiptPurchaseData == null;
if (flag4)
{
receiptPurchaseData = string.Empty;
}
bool flag5 = signature == null;
if (flag5)
{
signature = string.Empty;
}
result = Analytics.Transaction(productId, Convert.ToDouble(amount), currency, receiptPurchaseData, signature, usingIAPService);
}
return(result);
}