From: Adam M. <ama...@us...> - 2006-02-27 20:27:32
|
Update of /cvsroot/bibdesk/bibdesk In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11651 Modified Files: Tag: BR_1x PubMedParser.m Log Message: Fix bug #1438435; case in string was not correct. Index: PubMedParser.m =================================================================== RCS file: /cvsroot/bibdesk/bibdesk/PubMedParser.m,v retrieving revision 1.35.2.34 retrieving revision 1.35.2.35 diff -C2 -d -r1.35.2.34 -r1.35.2.35 *** PubMedParser.m 16 Feb 2006 10:32:53 -0000 1.35.2.34 --- PubMedParser.m 27 Feb 2006 20:26:43 -0000 1.35.2.35 *************** *** 299,312 **** } static void mergePageNumbers(NSMutableDictionary *dict) { - NSArray *keys = [dict allKeys]; NSString *merge; ! ! if([keys containsObject:@"Sp"] && [keys containsObject:@"Ep"]){ ! merge = [[[dict objectForKey:@"Sp"] stringByAppendingString:@"--"] stringByAppendingString:[dict objectForKey:@"EP"]]; ! [dict setObject:merge forKey:BDSKPagesString]; ! [dict removeObjectForKey:@"Sp"]; ! [dict removeObjectForKey:@"Ep"]; } } --- 299,319 ---- } + static NSString *RISStartPageString = @"Sp"; + static NSString *RISEndPageString = @"Ep"; + static void mergePageNumbers(NSMutableDictionary *dict) { NSString *merge; ! NSString *start = [dict objectForKey:RISStartPageString]; ! NSString *end = [dict objectForKey:RISEndPageString]; ! if(start != nil && end != nil){ ! NSMutableString *merge = [start mutableCopy]; ! [merge appendString:@"--"]; ! [merge appendString:end]; ! [dict setObject:merge forKey:BDSKPagesString]; ! [merge release]; ! ! [dict removeObjectForKey:RISStartPageString]; ! [dict removeObjectForKey:RISStartPageString]; } } |