|
@@ -514,11 +514,16 @@
|
|
- (NSString *)_checkIfSubtitleWasFound:(NSString *)filePath
|
|
- (NSString *)_checkIfSubtitleWasFound:(NSString *)filePath
|
|
{
|
|
{
|
|
NSString *subtitlePath;
|
|
NSString *subtitlePath;
|
|
|
|
+ NSString *fileSub;
|
|
|
|
+ NSString *currentPath;
|
|
|
|
+
|
|
NSString *fileName = [[filePath lastPathComponent] stringByDeletingPathExtension];
|
|
NSString *fileName = [[filePath lastPathComponent] stringByDeletingPathExtension];
|
|
|
|
+ if (fileName == nil)
|
|
|
|
+ return nil;
|
|
|
|
+
|
|
NSMutableArray *listOfSubtitles = [self _listOfSubtitles];
|
|
NSMutableArray *listOfSubtitles = [self _listOfSubtitles];
|
|
- NSString *fileSub;
|
|
|
|
NSUInteger count = listOfSubtitles.count;
|
|
NSUInteger count = listOfSubtitles.count;
|
|
- NSString *currentPath;
|
|
|
|
|
|
+
|
|
for (NSUInteger i = 0; i < count; i++) {
|
|
for (NSUInteger i = 0; i < count; i++) {
|
|
currentPath = listOfSubtitles[i];
|
|
currentPath = listOfSubtitles[i];
|
|
fileSub = [NSString stringWithFormat:@"%@", currentPath];
|
|
fileSub = [NSString stringWithFormat:@"%@", currentPath];
|