Skip to content

Commit f267ed6

Browse files
committed
fix label logic
1 parent 9cfb13c commit f267ed6

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

R/tm_g_distribution.R

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -601,7 +601,12 @@ srv_distribution <- function(id,
601601
gamma = c("shape", "rate"),
602602
unif = c("min", "max")
603603
)
604-
params_names <- map_distr_nams[[input$t_dist]] %||% names(params)
604+
605+
if (!is.null(input$t_dist) && input$t_dist %in% names(map_distr_nams)) {
606+
params_names <- map_distr_nams[[input$t_dist]]
607+
} else {
608+
params_names <- names(params)
609+
}
605610

606611
updateNumericInput(
607612
inputId = "dist_param1",

0 commit comments

Comments
 (0)