Skip to content

Commit cb8ca91

Browse files
committed
Resolve warning
1 parent 496d1ab commit cb8ca91

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

FirebaseRemoteConfig/SwiftNew/ConfigSettings.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -328,12 +328,12 @@ let RCNHTTPDefaultConnectionTimeout: TimeInterval = 60
328328
/// Updates the metadata table with the current fetch status.
329329
/// @param fetchSuccess True if fetch was successful.
330330
@objc public func updateMetadata(withFetchSuccessStatus fetchSuccess: Bool,
331-
templateVersion: String) {
331+
templateVersion: String?) {
332332
RCLog.debug("I-RCN000056", "Updating metadata with fetch result.")
333333
updateFetchTime(success: fetchSuccess)
334334
_lastFetchStatus = fetchSuccess ? .success : .failure
335335
_lastFetchError = RemoteConfigError(fetchSuccess ? .unknown : .internalError)
336-
if fetchSuccess {
336+
if fetchSuccess, let templateVersion {
337337
updateLastFetchTimeInterval(Date().timeIntervalSince1970)
338338
// Note: We expect the googleAppID to always be available.
339339
_deviceContext = Device.remoteConfigDeviceContext(with: _googleAppID)

0 commit comments

Comments
 (0)