From 8a1860a5c60cc4e19a9f5be463bafbaffb1c162e Mon Sep 17 00:00:00 2001 From: Sal Scotto Date: Wed, 7 Jul 2021 10:11:14 -0600 Subject: [PATCH] alternate location support for ios for a dowloaded epub, it wont be in the main bundle, but instead be in a Data Container, fromt hat container you can fetch the path, so can we make this more on par with android version either pass file name in bundle OR use the name as an abolute path --- src/epub-reader.ios.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/epub-reader.ios.ts b/src/epub-reader.ios.ts index 762bd60..8d5261d 100644 --- a/src/epub-reader.ios.ts +++ b/src/epub-reader.ios.ts @@ -14,7 +14,7 @@ export class EpubReader { return version; } open(fileName: string) { - let bookPath = NSBundle.mainBundle.pathForResourceOfType(fileName, 'epub'); + let bookPath = NSBundle.mainBundle.pathForResourceOfType(fileName, 'epub') || fileName; FolioReader.presentReaderWithParentViewControllerWithEpubPathAndConfigShouldRemoveEpubAnimated( topmost().currentPage.ios, bookPath,