From 656bf183b778e202430ec6a83246a4432be6cd51 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Thu, 8 Aug 2019 14:26:49 +0200 Subject: [PATCH] Make getHumanReadableFromPath method const. --- include/book.h | 2 +- src/book.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/book.h b/include/book.h index 836bbbe7e..e3bf185cd 100644 --- a/include/book.h +++ b/include/book.h @@ -45,7 +45,7 @@ class Book void update(const Reader& reader); void updateFromXml(const pugi::xml_node& node, const std::string& baseDir); void updateFromOpds(const pugi::xml_node& node, const std::string& urlHost); - std::string getHumanReadableIdFromPath(); + std::string getHumanReadableIdFromPath() const; bool readOnly() const { return m_readOnly; } const std::string& getId() const { return m_id; } diff --git a/src/book.cpp b/src/book.cpp index 4ef15a795..8fae56c79 100644 --- a/src/book.cpp +++ b/src/book.cpp @@ -156,7 +156,7 @@ void Book::updateFromOpds(const pugi::xml_node& node, const std::string& urlHost } #undef VALUE -std::string Book::getHumanReadableIdFromPath() +std::string Book::getHumanReadableIdFromPath() const { std::string id = m_path; if (!id.empty()) {