diff options
author | tastytea | 2020-01-06 16:43:14 +0100 |
---|---|---|
committer | tastytea | 2020-01-06 16:43:14 +0100 |
commit | 935c84e001e58e2411e12707c685a87744f65a87 (patch) | |
tree | 96d3698092e798b566b122bebaf5f3f904d01009 | |
parent | 27054d480ebee3c14e0105c5e88fd8be72d28ffc (diff) | |
download | mastodonpp-935c84e001e58e2411e12707c685a87744f65a87.tar mastodonpp-935c84e001e58e2411e12707c685a87744f65a87.tar.gz mastodonpp-935c84e001e58e2411e12707c685a87744f65a87.zip |
Search for all directories in shorten_filename().
-rw-r--r-- | src/log.hpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/log.hpp b/src/log.hpp index 286cd07..4d709b4 100644 --- a/src/log.hpp +++ b/src/log.hpp @@ -31,7 +31,7 @@ constexpr auto shorten_filename(const string_view &filename) { for (const string_view &dir : {"/src/", "/include/"}) { - auto pos{filename.rfind("/src/")}; + const auto pos{filename.rfind(dir)}; if (pos != string_view::npos) { return filename.substr(pos + dir.size()); |