Revision: 29915
http://sourceforge.net/p/bibdesk/svn/29915
Author: hofman
Date: 2025-11-30 17:11:19 +0000 (Sun, 30 Nov 2025)
Log Message:
-----------
no need to compare empty strings separately, stringValueOfField is never nil
Modified Paths:
--------------
trunk/bibdesk/BibItem.m
Modified: trunk/bibdesk/BibItem.m
===================================================================
--- trunk/bibdesk/BibItem.m 2025-11-30 17:08:24 UTC (rev 29914)
+++ trunk/bibdesk/BibItem.m 2025-11-30 17:11:19 UTC (rev 29915)
@@ -423,16 +423,10 @@
[keys addObjectsFromArray:[aBI allFieldNames]];
for (NSString *key in keys) {
- NSString *value1 = [self stringValueOfField:key inherit:NO];
- NSString *value2 = [aBI stringValueOfField:key inherit:NO];
- if ([NSString isEmptyString:value1]) {
- if ([NSString isEmptyString:value2] == NO)
- return NO;
- } else if ([NSString isEmptyString:value2]) {
- return NO;
- } else if ([value1 isEqualToString:value2] == NO) {
- return NO;
- }
+ if ([[self stringValueOfField:key inherit:NO] isEqualToString:[aBI
stringValueOfField:key inherit:NO]] == NO) {
+ // !!! early return
+ return NO;
+ }
}
return YES;
}
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit