diff --git a/Classes/Managed Objects/TSSTManagedGroup.m b/Classes/Managed Objects/TSSTManagedGroup.m index 781b7317..b618ff8b 100644 --- a/Classes/Managed Objects/TSSTManagedGroup.m +++ b/Classes/Managed Objects/TSSTManagedGroup.m @@ -135,7 +135,9 @@ - (NSURL *)fileURL { fileURL = nil; [[self managedObjectContext] deleteObject: self]; - [NSApp presentError: urlError]; + if (urlError) { + [NSApp presentError: urlError]; + } } else if (stale) { diff --git a/Classes/Managed Objects/TSSTPage.m b/Classes/Managed Objects/TSSTPage.m index 3e15ce0b..23f4f2ea 100644 --- a/Classes/Managed Objects/TSSTPage.m +++ b/Classes/Managed Objects/TSSTPage.m @@ -240,7 +240,7 @@ - (NSImage *)pageImage - (NSImage *)textPage { __block NSData * textData; - if(self.index) + if(self.index != nil) { [self.group requestDataForPageIndex: [self.index integerValue] completionHandler:^(NSData * _Nullable pageData, NSError * _Nullable error) { textData = pageData; @@ -302,7 +302,7 @@ - (NSData *)pageData { __block NSData * imageData = nil; TSSTManagedGroup * group = self.group; - if(self.index) + if(self.index != nil) { NSInteger entryIndex = [self.index integerValue]; [group requestDataForPageIndex:entryIndex completionHandler:^(NSData * _Nullable pageData, NSError * _Nullable error) { diff --git a/Classes/Session/TSSTSessionWindowController.m b/Classes/Session/TSSTSessionWindowController.m index a6b321be..e321a663 100644 --- a/Classes/Session/TSSTSessionWindowController.m +++ b/Classes/Session/TSSTSessionWindowController.m @@ -1165,6 +1165,9 @@ - (void)changeViewImages titleString = [NSString stringWithFormat:@"%@ — %@", fileName, titleString]; } } + if (fileName == nil) { + fileName = representationURL.lastPathComponent; + } if (@available(macOS 11.0, *)) { self.window.title = fileName; self.window.subtitle = [titleString stringByReplacingOccurrencesOfString:[NSString stringWithFormat:@"%@ — ", fileName] withString:@""]; diff --git a/QuickComic/DTPartialArchiveParser.m b/QuickComic/DTPartialArchiveParser.m index dc7797bf..a1d93352 100644 --- a/QuickComic/DTPartialArchiveParser.m +++ b/QuickComic/DTPartialArchiveParser.m @@ -50,7 +50,7 @@ -(void)archiveParser:(XADArchiveParser *)parser foundEntryWithDictionary:(NSDict if(!isres) { - XADString * name = dict[XADFileNameKey]; + id name = dict[XADFileNameKey]; NSString * encodedName = [name stringWithEncodingName:parser.encodingName]; // NSLog(@"Encoded Name: %@", encodedName); if([searchString isEqualToString: encodedName]) diff --git a/Vendor/XADMaster b/Vendor/XADMaster index bf43fa0e..fe83fd3d 160000 --- a/Vendor/XADMaster +++ b/Vendor/XADMaster @@ -1 +1 @@ -Subproject commit bf43fa0ed7d08e6419f44b14827a5cfe1cfa562c +Subproject commit fe83fd3ddc009d3608823f7b7df4b61cb13534d5