@@ -224,7 +224,7 @@ app_server <- function(input, output, session) {
224224 })
225225
226226 static_gene <- reactive({
227- gene_warnings = NULL
227+ gene_warning = NULL
228228 withCallingHandlers({
229229 p <- vis_gene(
230230 spe ,
@@ -258,10 +258,10 @@ app_server <- function(input, output, session) {
258258 )
259259 }
260260 }, warning = function (w ) {
261- gene_warnings <<- c( gene_warnings , conditionMessage(w ) )
261+ gene_warning <<- conditionMessage(w )
262262 invokeRestart(" muffleWarning" )
263263 })
264- return (list (p = p_result , gene_warnings = gene_warnings ))
264+ return (list (p = p_result , gene_warning = gene_warning ))
265265 })
266266
267267 static_gene_grid <- reactive({
@@ -455,7 +455,7 @@ app_server <- function(input, output, session) {
455455 height = 8 ,
456456 width = 8 * ifelse(input $ side_by_side_gene , 2 , 1 )
457457 )
458- print(static_gene())
458+ print(static_gene()[[ ' p ' ]] )
459459 dev.off()
460460 }
461461 )
@@ -483,7 +483,7 @@ app_server <- function(input, output, session) {
483483 height = 8 * isolate(input $ gene_grid_nrow ),
484484 width = 8 * isolate(input $ gene_grid_ncol )
485485 )
486- print(static_gene_grid()[' p' ])
486+ print(static_gene_grid()[[ ' p' ] ])
487487 dev.off()
488488 }
489489 )
@@ -560,13 +560,13 @@ app_server <- function(input, output, session) {
560560 # Since 'static_gene()' is invoked twice (once also in the assignment
561561 # of 'output$gene'), we silence any errors that occur in this second
562562 # invocation to not duplicate error messages
563- these_warnings = NULL
563+ this_warning = NULL
564564 temp = try(
565- { these_warnings = static_gene()[[' gene_warnings ' ]] }, silent = TRUE
565+ { this_warning = static_gene()[[' gene_warning ' ]] }, silent = TRUE
566566 )
567567
568- if (! is.null(these_warnings )) {
569- paste(" Warnings :" , paste( these_warnings , collapse = " ; " ) )
568+ if (! is.null(this_warning )) {
569+ paste(" Warning :" , this_warning )
570570 } else {
571571 " "
572572 }
0 commit comments