diff --git a/R/to_numeric.R b/R/to_numeric.R index e948d7cc1..55bcbe319 100644 --- a/R/to_numeric.R +++ b/R/to_numeric.R @@ -74,7 +74,7 @@ to_numeric.data.frame <- function(x, return(x) } - attr <- attributes(x) + df_attr <- attributes(x) # evaluate arguments select <- .select_nse(select, @@ -141,7 +141,7 @@ to_numeric.data.frame <- function(x, } # add back custom attributes - out <- .replace_attrs(out, attr) + out <- .replace_attrs(out, df_attr) out }