Revision: 22534
          http://sourceforge.net/p/bibdesk/svn/22534
Author:   hofman
Date:     2018-08-26 21:19:05 +0000 (Sun, 26 Aug 2018)
Log Message:
-----------
Remove unused declaration, no need to check parse errors

Modified Paths:
--------------
    trunk/bibdesk/BDSKMathSciNetParser.h
    trunk/bibdesk/BDSKMathSciNetParser.m
    trunk/bibdesk/BDSKNumdamParser.m
    trunk/bibdesk/BDSKProjectEuclidParser.m
    trunk/bibdesk/BDSKZentralblattParser.m

Modified: trunk/bibdesk/BDSKMathSciNetParser.h
===================================================================
--- trunk/bibdesk/BDSKMathSciNetParser.h        2018-08-26 16:28:57 UTC (rev 
22533)
+++ trunk/bibdesk/BDSKMathSciNetParser.h        2018-08-26 21:19:05 UTC (rev 
22534)
@@ -39,7 +39,6 @@
 #import <Cocoa/Cocoa.h>
 #import "BDSKAsynchronousWebParser.h"
 
-@protocol BDSKOwner;
 
 @interface BDSKMathSciNetParser : BDSKAsynchronousWebParser
 + (NSArray *)bibTeXRequestsForMRIDs:(NSArray *)IDs referrer:(NSURL *)URL 
error:(NSError **)outError;

Modified: trunk/bibdesk/BDSKMathSciNetParser.m
===================================================================
--- trunk/bibdesk/BDSKMathSciNetParser.m        2018-08-26 16:28:57 UTC (rev 
22533)
+++ trunk/bibdesk/BDSKMathSciNetParser.m        2018-08-26 21:19:05 UTC (rev 
22534)
@@ -89,13 +89,7 @@
 }
 
 - (NSArray *)itemsFromDownload:(BDSKCitationDownload *)download error:(NSError 
**)outError {
-    NSArray *results = nil;
-    NSString *bibTeXString = [download string];
-    
-    if (bibTeXString)
-        results = [BDSKMathSciNetParser itemsFromDownload:download parser:self 
error:outError];
-    
-    return results;
+    return [BDSKMathSciNetParser itemsFromDownload:download parser:self 
error:outError];
 }
 
 // Turns an array of MR ID numbers into an array of NSURLRequest objects to 
download the bibTeX citations.

Modified: trunk/bibdesk/BDSKNumdamParser.m
===================================================================
--- trunk/bibdesk/BDSKNumdamParser.m    2018-08-26 16:28:57 UTC (rev 22533)
+++ trunk/bibdesk/BDSKNumdamParser.m    2018-08-26 21:19:05 UTC (rev 22534)
@@ -142,7 +142,6 @@
     NSDictionary *contextInfo = [download contextInfo];
     Class parserClass = (Class)[contextInfo objectForKey:@"parserClass"];
     NSString *content = [contextInfo objectForKey:@"content"];
-    BOOL addLinkedFiles = NO == [[NSUserDefaults standardUserDefaults] 
boolForKey:BDSKUseLocalUrlAndUrlKey];
     
     results = [parserClass itemsFromDownload:download parser:self 
error:outError];
     
@@ -149,6 +148,7 @@
     if ([results count] > 0 && content != nil) {
         // add Numdam URL to item's own record
         BibItem *item = [results objectAtIndex:0];
+        BOOL addLinkedFiles = NO == [[NSUserDefaults standardUserDefaults] 
boolForKey:BDSKUseLocalUrlAndUrlKey];
         if ( [item isKindOfClass:[BibItem class]] ) {
             AGRegex * URLRegexp = [AGRegex regexWithPattern:@"stable URL: 
([a-zA-Z0-9:=./?_]*)" options:0];
             AGRegexMatch * match = [URLRegexp findInString:content];

Modified: trunk/bibdesk/BDSKProjectEuclidParser.m
===================================================================
--- trunk/bibdesk/BDSKProjectEuclidParser.m     2018-08-26 16:28:57 UTC (rev 
22533)
+++ trunk/bibdesk/BDSKProjectEuclidParser.m     2018-08-26 21:19:05 UTC (rev 
22534)
@@ -134,7 +134,6 @@
     NSDictionary *contextInfo = [download contextInfo];
     Class parserClass = (Class)[contextInfo objectForKey:@"parserClass"];
     NSString *myIdentifier = [contextInfo objectForKey:@"myIdentifier"];
-    BOOL addLinkedFiles = NO == [[NSUserDefaults standardUserDefaults] 
boolForKey:BDSKUseLocalUrlAndUrlKey];
     
     results = [parserClass itemsFromDownload:download parser:self 
error:&error];
     
@@ -141,6 +140,7 @@
     if ([results count] > 0 && myIdentifier != nil) {
         // add Project Euclid URL to item's own record
         NSObject * item = [results objectAtIndex:0];
+        BOOL addLinkedFiles = NO == [[NSUserDefaults standardUserDefaults] 
boolForKey:BDSKUseLocalUrlAndUrlKey];
         if ( [item isKindOfClass:[BibItem class]] ) {
             AGRegex * ProjectEuclidRegexp = [AGRegex 
regexWithPattern:@"(https://projecteuclid.org/[^\\s]*)" options:0];
             AGRegexMatch * match = [ProjectEuclidRegexp 
findInString:myIdentifier];

Modified: trunk/bibdesk/BDSKZentralblattParser.m
===================================================================
--- trunk/bibdesk/BDSKZentralblattParser.m      2018-08-26 16:28:57 UTC (rev 
22533)
+++ trunk/bibdesk/BDSKZentralblattParser.m      2018-08-26 21:19:05 UTC (rev 
22534)
@@ -38,7 +38,6 @@
 
 #import "BDSKZentralblattParser.h"
 #import "BibItem.h"
-#import "NSError_BDSKExtensions.h"
 #import "NSURL_BDSKExtensions.h"
 #import <AGRegex/AGRegex.h>
 
@@ -89,20 +88,7 @@
 }
 
 - (NSArray *)itemsFromDownload:(BDSKCitationDownload *)download error:(NSError 
**)outError {
-    NSArray *results = nil;
-    NSString *bibTeXString = [download string];
-    NSError *error = nil;
-    
-    if (bibTeXString) {
-        results = [BDSKZentralblattParser itemsFromDownload:download 
parser:self error:&error];
-        if ([results count] && [error 
isLocalErrorWithCode:kBDSKBibTeXParserFailed])
-            results = nil;
-    }
-    
-    if ([results count] == 0 && outError)
-        *outError = error;
-    
-    return results;
+    return [BDSKZentralblattParser itemsFromDownload:download parser:self 
error:outError];
 }
 
 // Turns an array of Zentralblatt Math IDs into an array of NSURLRequest 
objects for bibtex data.

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit

Reply via email to