-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from qonversion/release/2.1.3
Release/2.1.3
- Loading branch information
Showing
20 changed files
with
316 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
namespace QonversionUnity | ||
{ | ||
static class Constants | ||
{ | ||
public const string KeyPrefix = "com.qonversion.keys"; | ||
public const string SourceKey = KeyPrefix + ".source"; | ||
public const string VersionKey = KeyPrefix + ".sourceVersion"; | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
using System.Collections.Generic; | ||
|
||
namespace QonversionUnity | ||
{ | ||
public class Eligibility | ||
{ | ||
public readonly EligibilityStatus Status; | ||
|
||
public Eligibility(Dictionary<string, object> dict) | ||
{ | ||
if (dict.TryGetValue("status", out object value)) Status = FormatEligibilityStatus(value); | ||
} | ||
|
||
public override string ToString() | ||
{ | ||
return $"{nameof(Status)}: {Status}"; | ||
} | ||
|
||
private EligibilityStatus FormatEligibilityStatus(object status) { | ||
string value = status as string; | ||
EligibilityStatus result; | ||
switch (value) | ||
{ | ||
case "non_intro_or_trial_product": | ||
result = EligibilityStatus.NonIntroProduct; | ||
break; | ||
case "intro_or_trial_eligible": | ||
result = EligibilityStatus.Eligible; | ||
break; | ||
case "intro_or_trial_ineligible": | ||
result = EligibilityStatus.Ineligible; | ||
break; | ||
default: | ||
result = EligibilityStatus.Unknown; | ||
break; | ||
} | ||
|
||
return result; | ||
} | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
namespace QonversionUnity | ||
{ | ||
public enum EligibilityStatus | ||
{ | ||
Unknown, | ||
NonIntroProduct, | ||
Ineligible, | ||
Eligible | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.