Skip to content

Commit

Permalink
check iff max retries equal or greater than zero
Browse files Browse the repository at this point in the history
  • Loading branch information
jayahariv committed Feb 14, 2021
1 parent a34374a commit f4721aa
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Objective-C/CBLReplicatorConfiguration.m
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,8 @@ - (NSDictionary*) effectiveOptions {
if (_maxRetryWaitTime > 0)
options[@kC4ReplicatorOptionMaxRetryInterval] = @(_maxRetryWaitTime);

options[@kC4ReplicatorOptionMaxRetries] = @(_maxRetries);
if (_maxRetries >= 0)
options[@kC4ReplicatorOptionMaxRetries] = @(_maxRetries);

#ifdef COUCHBASE_ENTERPRISE
NSString* uniqueID = $castIf(CBLMessageEndpoint, _target).uid;
Expand Down

0 comments on commit f4721aa

Please sign in to comment.