Skip to content

Commit

Permalink
Use anyNA(.) over NA %in% .
Browse files Browse the repository at this point in the history
Discovered on GitHub search, related to work on r-lib/lintr#2113
  • Loading branch information
MichaelChirico authored Dec 14, 2023
1 parent 77fce9b commit 8faa20e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/lint.R
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ pkg_lifecycle_statuses <- function(package, which = c("superseded", "deprecated"
res <- vctrs::vec_rbind(!!!res)

# Filter funs without a lifecycle
if (!NA %in% which) {
if (!anyNA(which)) {
res <- res[!is.na(res$lifecycle), ]
}

Expand Down

0 comments on commit 8faa20e

Please sign in to comment.