MCPcopy Create free account
hub / github.com/atraczyk/2d-engine / ensureTrailingSlash

Function ensureTrailingSlash

engine/src/utils.cpp:79–85  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77}
78
79static std::string ensureTrailingSlash(std::string path) {
80 path = normalizePath(path);
81 if (!path.empty() && path.back() != '/') {
82 path.push_back('/');
83 }
84 return path;
85}
86
87static std::string buildCandidate(const std::string &root,
88 const std::string &relativePath) {

Callers 1

buildCandidateFunction · 0.85

Calls 1

normalizePathFunction · 0.85

Tested by

no test coverage detected