diff --git a/R/lifecycle_admiral.R b/R/lifecycle_admiral.R index c3e63ff7..8c232dab 100644 --- a/R/lifecycle_admiral.R +++ b/R/lifecycle_admiral.R @@ -8,6 +8,8 @@ #' #' @param ... See documentation for `lifecycle::deprecate_soft()` for additional argument use. #' +#' +#' #' @return `NULL`, invisibly. #' #' @examples @@ -27,11 +29,14 @@ #' #' #' @export -deprecate_inform <- function(...) { +deprecate_inform <- function( + env = caller_env(), + user_env = caller_env(2), + ...) { tryCatch( lifecycle::deprecate_soft( env = caller_env(), - user_env = caller_env(), + user_env = caller_env(2), ...), warning = \(w) { message(conditionMessage(w)) diff --git a/man/deprecate_inform.Rd b/man/deprecate_inform.Rd index 362d6806..ad62b110 100644 --- a/man/deprecate_inform.Rd +++ b/man/deprecate_inform.Rd @@ -4,14 +4,14 @@ \alias{deprecate_inform} \title{Deprecation with Soft Message} \usage{ -deprecate_inform(...) +deprecate_inform(env = caller_env(), user_env = caller_env(2), ...) } \arguments{ -\item{...}{See documentation for \code{lifecycle::deprecate_soft()} for additional argument use.} - \item{env}{See documentation for \code{lifecycle::deprecate_soft()}.} \item{user_env}{See documentation for \code{lifecycle::deprecate_soft()}.} + +\item{...}{See documentation for \code{lifecycle::deprecate_soft()} for additional argument use.} } \value{ \code{NULL}, invisibly.