R/check_nc_version.R

Defines functions check_nc_version

check_nc_version <- function(nc_version) {
  if (is.null(nc_version)) {
    stop("nc_version must not be NULL")
  }

  allowed_versions <- c(3, 4)
  if (!nc_version %in% allowed_versions) {
    stop("nc version must be in c(",
         paste0(allowed_versions, collapse = ", "),
         "), but was ", nc_version
    )
  }
}

Try the cmsafops package in your browser

Any scripts or data that you put into this service are public.

cmsafops documentation built on Sept. 18, 2023, 5:16 p.m.