diff --git a/R/args.R b/R/args.R index 683c15b9..3144fabb 100644 --- a/R/args.R +++ b/R/args.R @@ -859,9 +859,9 @@ validate_variational_args <- function(self) { #' @return `TRUE` invisibly unless an error is thrown. validate_pathfinder_args <- function(self) { - checkmate::assert_integerish(self$max_lbfgs_iter, lower = 1, null.ok = TRUE, len = 1) - if (!is.null(self$max_lbfgs_iter)) { - self$iter <- as.integer(self$max_lbfgs_iter) + checkmate::assert_integerish(self$max_lbfgs_iters, lower = 1, null.ok = TRUE, len = 1) + if (!is.null(self$max_lbfgs_iters)) { + self$iter <- as.integer(self$max_lbfgs_iters) } checkmate::assert_integerish(self$num_paths, lower = 1, null.ok = TRUE, len = 1) if (!is.null(self$num_paths)) { diff --git a/tests/testthat/testthat-problems.rds b/tests/testthat/testthat-problems.rds index b5499808..6767be0d 100644 Binary files a/tests/testthat/testthat-problems.rds and b/tests/testthat/testthat-problems.rds differ