Revision: 13791
          http://sourceforge.net/p/skim-app/code/13791
Author:   hofman
Date:     2023-11-21 18:10:18 +0000 (Tue, 21 Nov 2023)
Log Message:
-----------
Correct local variables for all variants

Modified Paths:
--------------
    trunk/SkimNotes/SKNDocument.m

Modified: trunk/SkimNotes/SKNDocument.m
===================================================================
--- trunk/SkimNotes/SKNDocument.m       2023-11-21 17:59:17 UTC (rev 13790)
+++ trunk/SkimNotes/SKNDocument.m       2023-11-21 18:10:18 UTC (rev 13791)
@@ -85,7 +85,7 @@
     
 #else
     
-    return [super writeToURL:absoluteURL ofType:typeName error:outError];
+    return [super writeToURL:absoluteURL ofType:docType error:outError];
     
 #endif
     
@@ -105,10 +105,11 @@
     NSArray *array = nil;
     NSError *error = nil;
     NSWorkspace *ws = [NSWorkspace sharedWorkspace];
-    NSFileManager *fm = [NSFileManager defaultManager];
     
 #if defined(FrameworkSample)
     
+    NSFileManager *fm = [NSFileManager defaultManager];
+    
     if ([ws type:docType conformsToType:SKNPDFDocumentType]) {
         array = [fm readSkimNotesFromExtendedAttributesAtURL:absoluteURL 
error:&error];
     } else if ([ws type:docType conformsToType:SKNPDFBundleDocumentType]) {
@@ -135,6 +136,9 @@
 
 #elif defined(ToolSample)
     
+    NSData *data = nil;
+    NSFileManager *fm = [NSFileManager defaultManager];
+    
     if ([ws type:docType conformsToType:SKNPDFDocumentType]) {
         NSString *path = [absoluteURL path];
         NSString *tmpDir = [NSTemporaryDirectory() 
stringByAppendingPathComponent:[[NSProcessInfo processInfo] 
globallyUniqueString]];
@@ -192,7 +196,7 @@
             @try { array = [NSKeyedUnarchiver unarchiveObjectWithData:data]; }
             @catch (id e) {}
             if (array == nil)
-                array = [NSPropertyListSerialization propertyListWithData:data 
options:NSPropertyListImmutable format:NULL errorDescription:NULL];
+                array = [NSPropertyListSerialization propertyListWithData:data 
options:NSPropertyListImmutable format:NULL error:NULL];
         } else {
             array = [NSArray array];
         }

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



_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to