Skip to content

Commit

Permalink
actually pass the call
Browse files Browse the repository at this point in the history
  • Loading branch information
hfrick committed Dec 16, 2024
1 parent 644531a commit 425d6cd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion R/grids.R
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,8 @@ make_random_grid <- function(...,
new_param_grid <- function(x = new_data_frame(), call = caller_env()) {
if (!is.data.frame(x)) {
cli::cli_abort(
"{.arg x} must be a data frame to construct a new grid from."
"{.arg x} must be a data frame to construct a new grid from.",
call = call
)
}

Expand Down
2 changes: 1 addition & 1 deletion tests/testthat/_snaps/grids.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,6 @@
Code
new_param_grid(as.matrix(x))
Condition
Error in `new_param_grid()`:
Error:
! `x` must be a data frame to construct a new grid from.

0 comments on commit 425d6cd

Please sign in to comment.