Skip to content

Commit

Permalink
not drop parameters when new_expr is NULL
Browse files Browse the repository at this point in the history
  • Loading branch information
joethorley committed Aug 9, 2024
1 parent c5302cd commit 59c0e48
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion R/drop-parameters.R
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,9 @@ drop_pars.mb_model <- function(x, pars = character(0), ...) {
}

x$code <- drop_pars(x$code, pars = pars)
x$new_expr <- drop_pars(x$new_expr, pars = pars)
if(!is.null(x$new_expr)) {
x$new_expr <- drop_pars(x$new_expr, pars = pars)
}
x$drops <- list()
x
}
Expand Down

0 comments on commit 59c0e48

Please sign in to comment.