diff --git a/R/file_checks.R b/R/file_checks.R index a645042..937287e 100644 --- a/R/file_checks.R +++ b/R/file_checks.R @@ -10,7 +10,7 @@ #' @export check_dir_writable <- function(dir) { log_trace("Checking if directory is writable: ", dir) - if (tolower(Sys.info()["sysname"]) == "windows") { + if (tolower(Sys.info()[["sysname"]]) == "windows") { log_warn("Function check_dir_writable is not tested on Windows.") warning("check_dir_writable may return incorrect results on Windows.") } diff --git a/tests/testthat/test-check_dir_writable.R b/tests/testthat/test-check_dir_writable.R index fc91e14..198335b 100644 --- a/tests/testthat/test-check_dir_writable.R +++ b/tests/testthat/test-check_dir_writable.R @@ -36,4 +36,3 @@ test_that("check_dir_writable emits warning on windows.", { regexp = "^check_dir_writable may return incorrect results on Windows.$" ) }) -