Skip to content

Commit

Permalink
[refactor] Explain what +8 does to get the path after default/
Browse files Browse the repository at this point in the history
  • Loading branch information
Toutou98 committed Jul 17, 2024
1 parent de6fd80 commit 7d2b10d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/dummy_daos/parallax.cc
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,8 @@ std::string get_path_after_default(const std::string &fullPath) {
// Find the position of "default/"
size_t pos = fullPath.find("default/");

return fullPath.substr(pos + 8); // +8 to skip "default/"
// +8 to skip "default/ because default/ has 8 characters"
return fullPath.substr(pos + 8);
}

std::string get_path_after_last_slash(const std::string &fullPath) {
Expand Down

0 comments on commit 7d2b10d

Please sign in to comment.