Skip to content

Commit 2ff2ac1

Browse files
committed
clarity
1 parent fc337aa commit 2ff2ac1

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

src/normalize.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,10 @@ fs_normal(std::string_view path)
6868
if (fs_slash_first(path))
6969
r.push_back('/');
7070

71-
for (const auto& p : parts)
71+
for (const auto& p : parts){
7272
r += p;
7373
r.push_back('/');
74+
}
7475

7576
#endif
7677

src/pure.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ std::string fs_root(std::string_view path)
133133
#else
134134
if (std::string r = fs_root_name(path); r.empty()){
135135
if (fs_slash_first(path))
136-
return std::string(path.substr(0, 1));
136+
return std::string(1, path.front());
137137

138138
return {};
139139
} else if (fs_is_windows()) {

0 commit comments

Comments
 (0)