R/zzz.R

Defines functions assert mssg

mssg <- function(v, ...) if (v) message(...)
assert <- function(x, y) {
  if (!is.null(x)) {
    if (!inherits(x, y)) {
      stop(deparse(substitute(x)), " must be of class ",
        paste0(y, collapse = ", "), call. = FALSE)
    }
  }
}
ropensci/taxizedb documentation built on April 28, 2023, 2:05 a.m.