Skip to content

Commit

Permalink
Merge pull request #1400 from corybrunson/declense
Browse files Browse the repository at this point in the history
declense verb in abort by 'offenders' quantity
  • Loading branch information
EmilHvitfeldt authored Nov 26, 2024
2 parents 59345e1 + d14ee24 commit e738967
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions R/selections.R
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
#' functions aren't restricted to predictors. They will thus select outcomes,
#' ID, and predictor columns alike. This is why these functions should be used
#' with care, and why [tidyselect::everything()] likely isn't what you need.
#'
#'
#' For example:
#'
#' \preformatted{
Expand Down Expand Up @@ -204,8 +204,8 @@ recipes_eval_select <- function(quos, data, info, ..., allow_rename = FALSE,
offenders <- offenders[offenders != ""]

cli::cli_abort(
"The following argument{?s} {?was/were} specified but do not exist: \\
{.arg {offenders}}.",
"The following argument{?s} {?was/were} specified but do{?es/} not exist: \\
{.arg {offenders}}.",
call = call
)
}
Expand Down
2 changes: 1 addition & 1 deletion tests/testthat/_snaps/basics.md
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@
Condition
Error in `step_pca()`:
Caused by error in `prep()`:
! The following argument was specified but do not exist: `number`.
! The following argument was specified but does not exist: `number`.

---

Expand Down
2 changes: 1 addition & 1 deletion tests/testthat/_snaps/rm.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Condition
Error in `step_rm()`:
Caused by error in `prep()`:
! The following argument was specified but do not exist: `sepal_length`.
! The following argument was specified but does not exist: `sepal_length`.

# empty printing

Expand Down

0 comments on commit e738967

Please sign in to comment.