diff --git a/R/CreateController.R b/R/CreateController.R index 060c139b56904a168396d1a8643bf2e6a87aa2f6..fb95c4d67ae433bee048193bc7e21155dac3dd5c 100644 --- a/R/CreateController.R +++ b/R/CreateController.R @@ -70,6 +70,7 @@ CreateController <- function(supervisor, ctrl.id, Y, U, FUN){ #' # For pointing the discharge at the oulet of basins "54095" and "54002" #' CreateControl(c("54095", "54002")) CreateControl <- function(locations, sv, isU) { + if (is.null(locations)) return(NULL) if (!is.character(locations)) { stop("Parameters `Y` and `U` should be character") }