From 1754244af0f75adc4cd9f62f3def7483e3f44e7f Mon Sep 17 00:00:00 2001 From: jamesaazam Date: Tue, 27 Aug 2024 12:59:18 +0100 Subject: [PATCH] Fix code style --- R/checks.R | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/R/checks.R b/R/checks.R index b5c721d6a..a43d8eb29 100644 --- a/R/checks.R +++ b/R/checks.R @@ -82,12 +82,13 @@ check_stan_delay <- function(dist) { # distributions with numeric parameters and infinite maximum numeric_or_normal <- unlist(lapply(seq_len(ndist(dist)), function(id) { if (get_distribution(dist, id) != "nonparametric") { - params <- get_parameters(dist, id) - vapply(params, function(x) { - is.numeric(x) || - (is(x, "dist_spec") && get_distribution(x) == "normal" && - is.infinite(max(x))) - }, logical(1))} + params <- get_parameters(dist, id) + vapply(params, function(x) { + is.numeric(x) || + (is(x, "dist_spec") && get_distribution(x) == "normal" && + is.infinite(max(x))) + }, logical(1)) + } })) if (!all(numeric_or_normal)) { stop(