diff --git a/R/utils.R b/R/utils.R index 18b793fec0..5b1e1346fb 100644 --- a/R/utils.R +++ b/R/utils.R @@ -1052,8 +1052,10 @@ validate <- function(..., errorClass = character(0)) { #' @rdname validate need <- function(expr, message = paste(label, "must be provided"), label) { - force(message) # Fail fast on message/label both being missing - + if (missing(label) && missing(message)) { + return("label is missing in `need()`") + } + if (!isTruthy(expr)) return(message) else