Skip to content

Commit

Permalink
use pluralization
Browse files Browse the repository at this point in the history
  • Loading branch information
IndrajeetPatil committed May 29, 2024
1 parent 0a8881e commit 776408d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions R/with.R
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,9 @@ modify_defaults <- function(defaults, ...) {

to_null <- vapply(vals, is.null, logical(1L))
if (!all(nms[to_null] %in% names(defaults))) {
bad_nms <- setdiff(nms[to_null], names(defaults))
is_are <- if (length(bad_nms) > 1L) "are" else "is" # nolint: object_usage_linter. TODO(#2252).
bad_nms <- setdiff(nms[to_null], names(defaults)) # nolint: object_usage_linter. TODO(#2252).
cli_warn(c(
i = "Trying to remove {.field {bad_nms}}, which {is_are} not in {.arg defaults}."
i = "Trying to remove {.field {bad_nms}}, which {?is/are} not in {.arg defaults}."
))
}

Expand Down

0 comments on commit 776408d

Please sign in to comment.