mirror of
https://github.com/rstudio/shiny.git
synced 2026-01-10 23:48:01 -05:00
Compare commits
1 Commits
v1.3-patch
...
joe/error-
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fc95ea7dca |
@@ -668,7 +668,10 @@ runApp <- function(appDir=getwd(),
|
||||
}
|
||||
)
|
||||
|
||||
return(.globals$retval)
|
||||
if (inherits(.globals$retval, "try-error"))
|
||||
stop(attr(.globals$retval, "condition", exact = TRUE))
|
||||
else
|
||||
return(.globals$retval)
|
||||
}
|
||||
|
||||
#' Stop the currently running Shiny app
|
||||
@@ -681,7 +684,7 @@ runApp <- function(appDir=getwd(),
|
||||
#'
|
||||
#' @export
|
||||
stopApp <- function(returnValue = NULL) {
|
||||
.globals$retval <- returnValue
|
||||
.globals$retval <- try(force(returnValue), silent = TRUE)
|
||||
.globals$stopped <- TRUE
|
||||
httpuv::interrupt()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user