Commit 76b9df44 authored by unknown's avatar unknown
Browse files

v1.0.9.21 CreateInputsModel now stops when DatesR contains duplicated values

Showing with 6 additions and 2 deletions
+6 -2
Package: airGR Package: airGR
Type: Package Type: Package
Title: Suite of GR Hydrological Models for Precipitation-Runoff Modelling Title: Suite of GR Hydrological Models for Precipitation-Runoff Modelling
Version: 1.0.9.20 Version: 1.0.9.21
Date: 2017-08-11 Date: 2017-08-16
Authors@R: c( Authors@R: c(
person("Laurent", "Coron", role = c("aut", "trl")), person("Laurent", "Coron", role = c("aut", "trl")),
person("Charles", "Perrin", role = c("aut", "ths")), person("Charles", "Perrin", role = c("aut", "ths")),
......
...@@ -79,6 +79,10 @@ CreateInputsModel <- function(FUN_MOD, ...@@ -79,6 +79,10 @@ CreateInputsModel <- function(FUN_MOD,
stop(paste( "the time step of the model inputs must be ", TimeStep, " seconds \n", sep = "")) stop(paste( "the time step of the model inputs must be ", TimeStep, " seconds \n", sep = ""))
return(NULL) return(NULL)
} }
if (anyDuplicated(DatesR) != 0) {
stop("DatesR must not include duplicated values \n")
return(NULL)
}
LLL <- length(DatesR) LLL <- length(DatesR)
} }
if ("GR" %in% ObjectClass) { if ("GR" %in% ObjectClass) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment