mirror of
https://github.com/standardebooks/web.git
synced 2025-07-16 03:16:36 -04:00
Get ebook from DB for artworks
This commit is contained in:
parent
c85db527cf
commit
4653b15288
2 changed files with 3 additions and 22 deletions
|
@ -259,7 +259,7 @@ class Artwork{
|
|||
}
|
||||
|
||||
/**
|
||||
* @throws Exceptions\AppException
|
||||
* @throws Exceptions\EbookNotFoundException
|
||||
*/
|
||||
protected function GetEbook(): ?Ebook{
|
||||
if($this->_Ebook === null){
|
||||
|
@ -267,8 +267,8 @@ class Artwork{
|
|||
return null;
|
||||
}
|
||||
|
||||
$ebookWwwFilesystemPath = preg_replace('|^https://standardebooks.org/ebooks/|ius', EBOOKS_DIST_PATH, $this->EbookUrl);
|
||||
$this->_Ebook = Library::GetEbook($ebookWwwFilesystemPath);
|
||||
$identifier = 'url:' . $this->EbookUrl;
|
||||
$this->_Ebook = Ebook::GetByIdentifier($identifier);
|
||||
}
|
||||
|
||||
return $this->_Ebook;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue