Revision: 29913
http://sourceforge.net/p/bibdesk/svn/29913
Author: hofman
Date: 2025-11-30 17:05:20 +0000 (Sun, 30 Nov 2025)
Log Message:
-----------
no need for intermediate set
Modified Paths:
--------------
trunk/bibdesk/BibItem.m
Modified: trunk/bibdesk/BibItem.m
===================================================================
--- trunk/bibdesk/BibItem.m 2025-11-30 16:55:22 UTC (rev 29912)
+++ trunk/bibdesk/BibItem.m 2025-11-30 17:05:20 UTC (rev 29913)
@@ -337,7 +337,7 @@
// compare only the standard fields; are these all we should compare?
BDSKTypeManager *btm = [BDSKTypeManager sharedManager];
- NSMutableSet *keys = [[NSMutableSet alloc] initWithCapacity:20];
+ NSMutableSet *keys = [[NSMutableSet alloc] init];
[keys addObjectsFromArray:[btm requiredFieldsForType:[self pubType]]];
[keys addObjectsFromArray:[btm optionalFieldsForType:[self pubType]]];
@@ -344,12 +344,10 @@
if ([keys count] == 0) {
// this is a type we don't know, just compare all fields
- NSMutableSet *set = [NSMutableSet set];
- [set addObjectsFromArray:[self allFieldNames]];
- [set addObjectsFromArray:[aBI allFieldNames]];
- [set removeObject:BDSKColorString];
- [set removeObject:BDSKLocalUrlString];
- [keys addObjectsFromArray:[set allObjects]];
+ [keys addObjectsFromArray:[self allFieldNames]];
+ [keys addObjectsFromArray:[aBI allFieldNames]];
+ [keys removeObject:BDSKColorString];
+ [keys removeObject:BDSKLocalUrlString];
}
[keys addObjectsFromArray:[btm userDefaultFieldsForType:[self
pubType]]];
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