diff --git a/R/output.R b/R/output.R index 07a3c0da77..c42132cfd0 100644 --- a/R/output.R +++ b/R/output.R @@ -472,7 +472,7 @@ sew.character = function(x, options, ...) { asis_token = '' wrap_asis = function(x, options) { x = as.character(x) - if ((n <- length(x)) == 0 || !out_format('markdown') || !isTRUE(options$collapse)) + if ((n <- length(x)) == 0 || !out_format('markdown') || missing(options) || !isTRUE(options$collapse)) return(x) x[1] = paste0(asis_token, x[1]) x[n] = paste0(x[n], asis_token)