diff --git a/R/tm_g_response.R b/R/tm_g_response.R index 57e1a9856..3ba6979f4 100644 --- a/R/tm_g_response.R +++ b/R/tm_g_response.R @@ -235,10 +235,12 @@ srv_g_response <- function(id, rule_diff <- function(other) { function(value) { - othervalue <- selector_list()[[other]]()[["select"]] - if (!is.null(othervalue)) { - if (identical(value, othervalue)) { - "Row and column facetting variables must be different." + if (other %in% names(selector_list())) { + othervalue <- selector_list()[[other]]()[["select"]] + if (!is.null(othervalue)) { + if (identical(value, othervalue)) { + "Row and column facetting variables must be different." + } } } }