I'm following the documentation for setting up Firebase for iOS.
remoteConfig = RemoteConfig.remoteConfig()
remoteConfig.setDefaults(fromPlist: "FirebaseRemoteConfigDefaults")
let settings = RemoteConfigSettings()
settings.minimumFetchInterval = 0
remoteConfig.configSettings = settings
print("Remote Config Response:\(self.remoteConfig.value(forKey: "OnboardingGroup"))")
Then it crashes when trying to get the value saying "this class is not key value coding-compliant for the key OnboardingGroup.'"
Not really sure where I might be going wrong. Would appreciate any help with this.
Here is my FirebaseRemoteConfigDefaults.plist:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>OnboardingGroup</key>
<string>group-1</string>
</dict>
</plist>
but it also crashes when setting the value manually.
Turns out I needed to use configValue(for: key) instead of value(for: key). Leaving this here in case anybody else runs into this.