Skip to content

Commit

Permalink
#521 fix separator for missing packages in checks for tm_g_distributi…
Browse files Browse the repository at this point in the history
…on and tm_g_scatterplot
  • Loading branch information
m7pr committed Jun 27, 2023
1 parent cf5e2c3 commit 5387684
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion R/tm_g_distribution.R
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ tm_g_distribution <- function(label = "Distribution Module",
if (length(missing_packages) > 0L) {
stop(sprintf(
"Cannot load package(s): %s.\nInstall or restart your session.",
paste(missing_packages, sep = ", ")
toString(missing_packages)
))
}

Expand Down
6 changes: 4 additions & 2 deletions R/tm_g_scatterplot.R
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,10 @@ tm_g_scatterplot <- function(label = "Scatterplot",
extra_packages <- c("ggpmisc", "ggExtra", "colourpicker")
missing_packages <- Filter(function(x) !requireNamespace(x, quietly = TRUE), extra_packages)
if (length(missing_packages) > 0L) {
stop(sprintf("Cannot load package(s): %s.\nInstall or restart your session.",
paste(missing_packages, sep = ", ")))
stop(sprintf(
"Cannot load package(s): %s.\nInstall or restart your session.",
toString(missing_packages)
))
}

if (inherits(x, "data_extract_spec")) x <- list(x)
Expand Down

0 comments on commit 5387684

Please sign in to comment.