Skip to content

Commit

Permalink
changing dots_list() to list2() per tidyverse#234
Browse files Browse the repository at this point in the history
  • Loading branch information
lbouzoubaa committed Jan 31, 2020
1 parent 5c6aabe commit bcad77a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion R/c.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#' fs <- list(fa, fb, fab)
#' fct_c(!!!fs)
fct_c <- function(...) {
fs <- rlang::dots_list(...)
fs <- rlang::list2(...)
fs <- check_factor_list(fs, "...")

if (length(fs) == 0) {
Expand Down
4 changes: 2 additions & 2 deletions R/collapse.R
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
#' )
#' fct_count(partyid2)
fct_collapse <- function(.f, ..., group_other = FALSE) {
new <- rlang::dots_list(...)
new <- rlang::list2(...)
levs <- as.list(unlist(new, use.names = FALSE))

if (group_other) {
f <- check_factor(.f)
levels <- levels(f)
Expand Down
2 changes: 1 addition & 1 deletion R/recode.R
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ fct_recode <- function(.f, ...) {
}

check_recode_levels <- function(...) {
levels <- rlang::dots_list(...)
levels <- rlang::list2(...)

is_ok <- function(x) is.character(x) && length(x) == 1
ok <- vapply(levels, is_ok, logical(1))
Expand Down

0 comments on commit bcad77a

Please sign in to comment.