Umm… nothing to see here… 😄
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
tastytea 2021-06-01 16:47:47 +02:00
parent 1dd6235260
commit 40e39dc0e7
Signed by: tastytea
GPG Key ID: CFC39497F1B26E07

View File

@ -211,20 +211,13 @@ std::vector<std::string> list_spine(const fs::path &filepath)
{ {
const auto &idref{itemref.attribute("idref").value()}; const auto &idref{itemref.attribute("idref").value()};
const auto &item{manifest.find_child_by_attribute("id", idref)}; const auto &item{manifest.find_child_by_attribute("id", idref)};
const auto href{ auto href{helpers::urldecode(item.attribute("href").value())};
helpers::urldecode(item.attribute("href").value())};
const auto real_href{
[&href, &spine_filepaths, &opf_file_path]
{
if (href[0] != '/') if (href[0] != '/')
{ {
return spine_filepaths.emplace_back( href = (opf_file_path.parent_path() /= href);
opf_file_path.parent_path() /= href);
} }
return href; DEBUGLOG << "Found in spine: " << href;
}()}; spine_filepaths.emplace_back(href);
DEBUGLOG << "Found in spine: " << real_href;
spine_filepaths.emplace_back(real_href);
} }
} }
else else