Skip to content

Commit c65c2de

Browse files
authored
Merge pull request #65 from KoenRijpstra/check-setup
Check if the user has setup the Server URI and Application Id
2 parents bfd902a + 0e87d9d commit c65c2de

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Assets/MoralisWeb3ApiSdk/MoralisController.cs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,13 @@ public class MoralisController : MonoBehaviour
5555
public string ApplicationUrl;
5656

5757
public WalletConnect walletConnect;
58-
58+
private void OnValidate()
59+
{
60+
if (MoralisServerURI == "SERVER URI" || string.IsNullOrWhiteSpace(MoralisServerURI) || MoralisApplicationId == "APPLICATION ID" || string.IsNullOrWhiteSpace(MoralisApplicationId))
61+
{
62+
Debug.LogError("Setup your Moralis Server URI and Application Id before running. For more help read the Quick Start on: https://github.com/ethereum-boilerplate/ethereum-unity-boilerplate#-quick-start");
63+
}
64+
}
5965

6066
#if UNITY_WEBGL
6167
public async UniTask Initialize()

0 commit comments

Comments
 (0)