Skip to content

Commit

Permalink
Add missing %||%
Browse files Browse the repository at this point in the history
  • Loading branch information
hadley committed Aug 7, 2024
1 parent d4d6583 commit cf79fc1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -101,3 +101,7 @@ catch_base_log <- function(level, namespace, .topcall = sys.call(-1), .topenv =
in_pkgdown <- function() {
identical(Sys.getenv("IN_PKGDOWN"), "true")
}

`%||%` <- function(x, y) {
if (is.null(x)) y else x
}

0 comments on commit cf79fc1

Please sign in to comment.