Skip to content

Commit 3644d2c

Browse files
committed
Rename to common_parts for clarity
1 parent 3d933d5 commit 3644d2c

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

R/path.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -244,9 +244,9 @@ path_rel_impl <- function(path, start) {
244244
# path_rel_one() is called once per element of `path`, so its argument is a
245245
# single vector of the split components of a single path.
246246
path_rel_one <- function(path_parts) {
247-
common <- path_common_parts(starts, path_parts)
247+
common_parts <- path_common_parts(starts, path_parts)
248248

249-
i <- length(common)
249+
i <- length(common_parts)
250250
double_dot_part <- rep("..", (length(starts) - i))
251251
if (i + 1 <= length(path_parts)) {
252252
path_part <- path_parts[seq(i + 1, length(path_parts))]
@@ -476,8 +476,8 @@ path_common <- function(path) {
476476
parts <- path_split(path)
477477
s1 <- parts[[1]]
478478
s2 <- parts[[length(parts)]]
479-
common <- path_common_parts(s1, s2)
480-
path_join(common)
479+
common_parts <- path_common_parts(s1, s2)
480+
path_join(common_parts)
481481
}
482482

483483
#' Find the common leading components of two already-split paths

0 commit comments

Comments
 (0)