Skip to content

Commit

Permalink
tdata to teal_data - tm_g_response (#607)
Browse files Browse the repository at this point in the history
adapted to new `teal_data` class
  • Loading branch information
chlebowa authored Nov 23, 2023
1 parent 522747b commit edc1f0c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions R/tm_g_response.R
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,8 @@ srv_g_response <- function(id,
ggplot2_args) {
with_reporter <- !missing(reporter) && inherits(reporter, "Reporter")
with_filter <- !missing(filter_panel_api) && inherits(filter_panel_api, "FilterPanelAPI")
checkmate::assert_class(data, "tdata")
checkmate::assert_class(data, "reactive")
checkmate::assert_class(isolate(data()), "teal_data")
moduleServer(id, function(input, output, session) {
data_extract <- list(response = response, x = x, row_facet = row_facet, col_facet = col_facet)

Expand Down Expand Up @@ -276,13 +277,12 @@ srv_g_response <- function(id,

anl_merged_input <- teal.transform::merge_expression_srv(
selector_list = selector_list,
datasets = data,
join_keys = teal.data::join_keys(data)
datasets = data
)

anl_merged_q <- reactive({
req(anl_merged_input())
teal.code::new_qenv(tdata2env(data), code = get_code_tdata(data)) %>%
data() %>%
teal.code::eval_code(as.expression(anl_merged_input()$expr))
})

Expand Down

0 comments on commit edc1f0c

Please sign in to comment.