Skip to content

Commit

Permalink
Clean up some partial matches.
Browse files Browse the repository at this point in the history
(I don't know a sane way to test this, which may make it futile?)
  • Loading branch information
craigcitro committed Feb 15, 2015
1 parent 9415a8a commit a1da9ba
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion R/install.r
Expand Up @@ -65,7 +65,7 @@ install <- function(pkg = ".", reload = TRUE, quick = FALSE, local = TRUE,
install_deps(pkg, dependencies = dependencies, threads = threads)

# Build the package. Only build locally if it doesn't have vignettes
has_vignettes <- length(tools::pkgVignettes(dir = pkg$path)$doc > 0)
has_vignettes <- length(tools::pkgVignettes(dir = pkg$path)$docs > 0)
if (local && !(has_vignettes && build_vignettes)) {
built_path <- pkg$path
} else {
Expand Down
2 changes: 1 addition & 1 deletion R/vignettes.r
Expand Up @@ -16,7 +16,7 @@
build_vignettes <- function(pkg = ".") {
pkg <- as.package(pkg)
vigns <- tools::pkgVignettes(dir = pkg$path)
if (length(vigns$doc) == 0) return()
if (length(vigns$docs) == 0) return()

message("Building ", pkg$package, " vignettes")
tools::buildVignettes(dir = pkg$path, tangle = TRUE)
Expand Down
2 changes: 1 addition & 1 deletion tests/testthat/test-load-hooks.r
Expand Up @@ -8,7 +8,7 @@ test_that("hooks called in correct order", {
}
}
reset_events <- function() {
assign("hooks", new.env(parent = emptyenv()), env = globalenv())
assign("hooks", new.env(parent = emptyenv()), envir = globalenv())
h <- globalenv()$hooks
h$events <- character()
}
Expand Down

0 comments on commit a1da9ba

Please sign in to comment.