Skip to content

Commit 4f3a42d

Browse files
committed
refac: udpate comman executor api for unity 2018.2 compatibility
1 parent 44a7003 commit 4f3a42d

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Assets/Test/Scripts/CommandExecutor.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -404,7 +404,8 @@ private void Config()
404404
{
405405
updatedJsonResponse = new Dictionary<string, object>(attribution.JsonResponse);
406406
updatedJsonResponse.Remove("fb_install_referrer");
407-
if (updatedJsonResponse.TryGetValue("cost_amount", out var costAmount) && costAmount is IConvertible)
407+
object costAmount;
408+
if (updatedJsonResponse.TryGetValue("cost_amount", out costAmount) && costAmount is IConvertible)
408409
{
409410
updatedJsonResponse["cost_amount"] = string.Format("{0:0.00}", System.Convert.ToDouble(costAmount));
410411
}
@@ -1023,7 +1024,8 @@ private void AttributionGetter()
10231024
{
10241025
updatedJsonResponse = new Dictionary<string, object>(attribution.JsonResponse);
10251026
updatedJsonResponse.Remove("fb_install_referrer");
1026-
if (updatedJsonResponse.TryGetValue("cost_amount", out var costAmount) && costAmount is IConvertible)
1027+
object costAmount;
1028+
if (updatedJsonResponse.TryGetValue("cost_amount", out costAmount) && costAmount is IConvertible)
10271029
{
10281030
updatedJsonResponse["cost_amount"] = string.Format("{0:0.00}", System.Convert.ToDouble(costAmount));
10291031
}

0 commit comments

Comments
 (0)