Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question Should use ConfigManager.appConfg.GetString for all origin types?

Discussion in 'Unity Remote Config' started by LesBloom, Feb 4, 2022.

  1. LesBloom

    LesBloom

    Joined:
    Feb 2, 2017
    Posts:
    161
    Hello,

    If, for some reason, my FetchConfigs call results in a response other then Success/Remote, do I still call ConfigManager.appConfg.GetString to get the key/value pairs?

    Will this method know to pull from the local cache or default values when appropriate?

    Or do I need to switch off of the ConfigFesponse.requestOrigin value and query some other method?

    Thank you
     
  2. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    14,446
    Yes, still use GetString. If no Internet, it will automatically pull from the local cache (if there was a previous successful connection) or use the default if not.
     
  3. LesBloom

    LesBloom

    Joined:
    Feb 2, 2017
    Posts:
    161
    Awesome! Thank you for the quick reply, @JeffDUnity3D, I appreciate it. Cheers