Fixed wrong Domain retrieving.

This commit is contained in:
Max Rahleev 2017-08-03 16:40:18 +03:00
parent 9a0fe67886
commit 008ecb1468
1 changed files with 2 additions and 2 deletions

View File

@ -48,8 +48,8 @@ open class ReCaptcha: ReCaptchaWebViewManager {
guard let apiKey = apiKey ?? (infoDict?[Constants.InfoDictKeys.APIKey] as? String) else {
throw NSError(code: .apiKeyNotFound)
}
guard let domain = infoDict?[Constants.InfoDictKeys.Domain] as? String, let baseURL = baseURL ?? URL(string: domain) else {
guard let baseURL = baseURL ?? URL(string: (infoDict?[Constants.InfoDictKeys.Domain] as? String) ?? "") else {
throw NSError(code: .baseURLNotFound)
}