From 741300390b042889f5b60578ed7e0f9ce41963c5 Mon Sep 17 00:00:00 2001 From: Matt Nield <64328730+matthewjnield@users.noreply.github.com> Date: Sun, 1 Jan 2023 11:54:47 -0500 Subject: [PATCH] Fix `str_view_all()` deprecation warning (#490) Fixes #485 --- R/view.R | 2 +- tests/testthat/_snaps/view.md | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/R/view.R b/R/view.R index a7dae6a4..e6f2280c 100644 --- a/R/view.R +++ b/R/view.R @@ -80,7 +80,7 @@ str_view <- function(string, pattern = NULL, match = TRUE, html = FALSE, use_esc #' @usage NULL #' @export str_view_all <- function(string, pattern = NULL, match = NA, html = FALSE, use_escapes = FALSE) { - lifecycle::deprecate_warn("1.5.0", "str_view()", "str_view_all()") + lifecycle::deprecate_warn("1.5.0", "str_view_all()", "str_view()") str_view( string = string, diff --git a/tests/testthat/_snaps/view.md b/tests/testthat/_snaps/view.md index 6526f91c..00044c8d 100644 --- a/tests/testthat/_snaps/view.md +++ b/tests/testthat/_snaps/view.md @@ -97,8 +97,8 @@ str_view_all("abc", "a|b") Condition Warning: - `str_view()` was deprecated in stringr 1.5.0. - i Please use `str_view_all()` instead. + `str_view_all()` was deprecated in stringr 1.5.0. + i Please use `str_view()` instead. Output [1] | c