Skip to content

Commit

Permalink
修复BUG:若xcarchive里面包含通知栏组件时,会取到通知栏组件的dSYM文件,导致和crash报告中的uuid不一致的情况
Browse files Browse the repository at this point in the history
  • Loading branch information
JJson committed Aug 25, 2017
1 parent c15e561 commit 7acadf4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Objective-C/DSYMTools/Controller/MainWindowViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ - (void)handleArchiveFileWithPath:(NSArray *)filePaths {
archiveInfo.archiveFileName = fileName;
archiveInfo.archiveFileType = ArchiveFileTypeXCARCHIVE;
[self formatArchiveInfo:archiveInfo];
}else if([fileName hasSuffix:@".dSYM"]){
}else if([fileName hasSuffix:@".app.dSYM"]){
archiveInfo.dSYMFilePath = filePath;
archiveInfo.dSYMFileName = fileName;
archiveInfo.archiveFileType = ArchiveFileTypeDSYM;
Expand All @@ -125,7 +125,7 @@ - (void)formatArchiveInfo:(ArchiveInfo *)archiveInfo{
NSArray *keys = @[@"NSURLPathKey",@"NSURLFileResourceTypeKey",@"NSURLIsDirectoryKey",@"NSURLIsPackageKey"];
NSArray *dSYMSubFiles= [[NSFileManager defaultManager] contentsOfDirectoryAtURL:[NSURL fileURLWithPath:dSYMsDirectoryPath] includingPropertiesForKeys:keys options:(NSDirectoryEnumerationSkipsHiddenFiles | NSDirectoryEnumerationSkipsPackageDescendants) error:nil];
for(NSURL *fileURLs in dSYMSubFiles){
if ([[fileURLs.relativePath lastPathComponent] hasSuffix:@"dSYM"]){
if ([[fileURLs.relativePath lastPathComponent] hasSuffix:@"app.dSYM"]){
archiveInfo.dSYMFilePath = fileURLs.relativePath;
archiveInfo.dSYMFileName = fileURLs.relativePath.lastPathComponent;
}
Expand Down

0 comments on commit 7acadf4

Please sign in to comment.