From 57a197d38dd50fae6d4a34c8740032a01f2a66d7 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Mon, 12 Mar 2018 17:28:29 +0100 Subject: [PATCH] Make getCurrentBookId const. --- include/manager.h | 2 +- src/manager.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/manager.h b/include/manager.h index d6e0144d..6fb74d22 100644 --- a/include/manager.h +++ b/include/manager.h @@ -129,7 +129,7 @@ class Manager * * @return The id of the current book (or empty string if no current book). */ - string getCurrentBookId(); + string getCurrentBookId() const; /** * Set the path of the external fulltext index associated to a book. diff --git a/src/manager.cpp b/src/manager.cpp index 72b0f8ea..b0e307c5 100644 --- a/src/manager.cpp +++ b/src/manager.cpp @@ -243,7 +243,7 @@ bool Manager::setCurrentBookId(const string id) return true; } -string Manager::getCurrentBookId() +string Manager::getCurrentBookId() const { return library.current.empty() ? "" : library.current.top(); }