-
Notifications
You must be signed in to change notification settings - Fork 297
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update LiteCore to 3.2.0-94 #3191
Conversation
Objective-C/CBLDatabase.mm
Outdated
@@ -796,7 +796,7 @@ - (nullable CBLCollection*) collectionWithName: (NSString*)name | |||
C4Error c4err = {}; | |||
C4Collection* c4col = c4db_getCollection(_c4db, spec, &c4err); | |||
if (!c4col) { | |||
if (c4err.code != 0) { | |||
if (c4err.code != 7) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use the constant variable instead of the number value? Also we will need to check for the error domain as well.
Objective-C/CBLDatabase.mm
Outdated
@@ -796,7 +796,7 @@ - (nullable CBLCollection*) collectionWithName: (NSString*)name | |||
C4Error c4err = {}; | |||
C4Collection* c4col = c4db_getCollection(_c4db, spec, &c4err); | |||
if (!c4col) { | |||
if (c4err.code != 0) { | |||
if (c4err.code != kC4ErrorNotFound && c4err.domain == LiteCoreDomain) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be
!(c4err.code == kC4ErrorNotFound && c4err.domain == LiteCoreDomain)
or
c4err.code != kC4ErrorNotFound || c4err.domain != LiteCoreDomain
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i mistyped ... wanted to be c4err.domain !=
I also didn't know if (!())
is allowed. will modify to that at it is more clear
No description provided.