Skip to content

Commit

Permalink
session issue
Browse files Browse the repository at this point in the history
  • Loading branch information
DivadNojnarg committed Jan 22, 2024
1 parent 3263534 commit 62b0e12
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions R/helpers-charts.R
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,12 @@ create_calendar_chart <- function(

Date <- Freq <- NULL

session <- get("session", parent.frame(2))
tryCatch({
session <- get("session", parent.frame(2))
ns <- session$ns
}, error = function(e) {
ns <- identity
})

renderEcharts4r({
validate(need(nrow(calendar_data()) > 0, "No calendar data found ..."))
Expand Down Expand Up @@ -60,7 +65,7 @@ create_calendar_chart <- function(
"function(e) {
Shiny.setInputValue('%s', e.data.value[0], {priority: 'event'});
}",
session$ns("selected_date")
ns("selected_date")
)
)

Expand Down

0 comments on commit 62b0e12

Please sign in to comment.