Adium

Changeset 24053

Show
Ignore:
Timestamp:
06/23/2008 11:50:01 PM (5 months ago)
Author:
evands
Message:

Fix content searching for logs created since we switch to bundles for chatlogs. Fixes #10155

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Source/AIMDLogViewerWindowController.m

    r18667 r24053  
    9595                        CFStringRef             logPath = CFURLCopyFileSystemPath(url, kCFURLPOSIXPathStyle); 
    9696                        NSArray                 *pathComponents = [(NSString *)logPath pathComponents]; 
    97                          
     97 
     98                        /* Handle chatlogs-as-bundles, which have an xml file inside our target .chatlog path */ 
     99                        if ([[[pathComponents lastObject] pathExtension] caseInsensitiveCompare:@"xml"] == NSOrderedSame) 
     100                                pathComponents = [pathComponents subarrayWithRange:NSMakeRange(0, [pathComponents count] - 1)]; 
     101 
    98102                        //Don't test for the date now; we'll test once we've found the AIChatLog if we make it that far 
    99103                        if ([self searchShouldDisplayDocument:document pathComponents:pathComponents testDate:NO]) {