mirror of
https://github.com/kiwix/libkiwix.git
synced 2025-06-27 21:39:37 +00:00
Dropped Book::getMutableDefaultIllustration()
Now a Book is created without a default illustration.
This commit is contained in:
@ -40,8 +40,6 @@ Book::Book() :
|
||||
m_pathValid(false),
|
||||
m_readOnly(false)
|
||||
{
|
||||
const auto illustration = std::make_shared<Illustration>();
|
||||
m_illustrations.assign(1, illustration);
|
||||
}
|
||||
|
||||
/* Destructor */
|
||||
@ -243,12 +241,6 @@ const Book::Illustration& Book::getDefaultIllustration() const
|
||||
throw std::runtime_error("No default illustration");
|
||||
}
|
||||
|
||||
Book::Illustration& Book::getMutableDefaultIllustration()
|
||||
{
|
||||
const Book* const const_this = this;
|
||||
return const_cast<Illustration&>(const_this->getDefaultIllustration());
|
||||
}
|
||||
|
||||
const std::string& Book::Illustration::getData() const
|
||||
{
|
||||
if (data.empty() && !url.empty()) {
|
||||
|
Reference in New Issue
Block a user