Fixed a devtools check() issue
This commit is contained in:
@@ -80,17 +80,17 @@ printDebug <- function(fn_name, table, key, tbl, rows, query_only = FALSE) {
|
|||||||
|
|
||||||
return_keys <- NULL
|
return_keys <- NULL
|
||||||
if (key %in% colnames(rows)) {
|
if (key %in% colnames(rows)) {
|
||||||
return_keys <- rows %>%
|
return_keys <- rows |>
|
||||||
dplyr::select(key)
|
dplyr::select(key)
|
||||||
} else {
|
} else {
|
||||||
return_keys <- rows %>%
|
return_keys <- rows |>
|
||||||
dplyr::bind_rows(tibble::tibble(!!key := character(0))) %>%
|
dplyr::bind_rows(tibble::tibble(!!key := character(0))) |>
|
||||||
dplyr::mutate(
|
dplyr::mutate(
|
||||||
!!key := dplyr::coalesce(
|
!!key := dplyr::coalesce(
|
||||||
!!!dplyr::sym(key),
|
!!!dplyr::sym(key),
|
||||||
paste0("<<NEW_ID::", round(stats::runif(1, 1, 100000)), ">>")
|
paste0("<<NEW_ID::", round(stats::runif(1, 1, 100000)), ">>")
|
||||||
)
|
)
|
||||||
) %>%
|
) |>
|
||||||
dplyr::select(key)
|
dplyr::select(key)
|
||||||
}
|
}
|
||||||
return(invisible(return_keys))
|
return(invisible(return_keys))
|
||||||
|
|||||||
Reference in New Issue
Block a user