diff --git a/R/vertmap.R b/R/vertmap.R index 7e86a87..fd16f9e 100644 --- a/R/vertmap.R +++ b/R/vertmap.R @@ -52,7 +52,7 @@ vertmap <- function(input = NULL, mapdatabase = "world", region = ".", geom = geom_point, jitter = NULL) { - if (!class(input) %in% c("list", "data.frame")) { + if (!inherits(input, c("list", "data.frame"))) { stop("Input must be of class list or data.frame", call. = FALSE) } diff --git a/R/yyy.R b/R/yyy.R index 389072b..9a9132b 100644 --- a/R/yyy.R +++ b/R/yyy.R @@ -3,7 +3,7 @@ sw <- function(x) suppressWarnings(x) vertsumwrapper <- function(input = NULL, verbose = TRUE){ - if (!class(input) %in% c("list", "data.frame")) { + if (!inherits(input, c("list", "data.frame"))) { stop("Input must be of class list or data.frame", call. = FALSE) } if (inherits(input, "list")) input <- input$data