R/nested_list.R
changed.
Other files ignored by Codecov
man/nested_list.Rd
has changed.
24 | 24 | #' nested_list(x) |
|
25 | 25 | #' nested_list(x, pre = " ") |
|
26 | 26 | #' nested_list(x, type = "headers", pre= "#", quote = "'") |
|
27 | - | nested_list <- function(x, type = "unordered", pre = "", quote = "") { |
|
27 | + | nested_list <- function(x, pre = "", quote = "", type = "unordered") { |
|
28 | 28 | txt <- c() |
|
29 | 29 | if (type == "unordered") parameters= c("* "," ",": ") |
|
30 | 30 | if (type == "ordered") parameters= c("1. "," ",": ") |
64 | 64 | pre2 <- paste0(pre, parameters[2]) |
|
65 | 65 | txt <- lapply(seq_along(x), function(i) { |
|
66 | 66 | item <- x[[i]] |
|
67 | - | sub <- nested_list(item, type,pre2, quote) |
|
67 | + | sub <- nested_list(item, pre2, quote,type) |
|
68 | 68 | # add line break unless item is unnamed and length = 1 |
|
69 | 69 | lbreak <- ifelse(length(item) > 1 | (length(names(item)) > 0), "\n", "") |
|
70 | 70 | if (grepl("\n", sub)) lbreak <- "\n" |
Files | Coverage |
---|---|
R | 95.75% |
Project Totals (31 files) | 95.75% |