Skip to content

Commit c20190c

Browse files
committed
Fix crash when callr option default is NULL
Dev callr (about to be submitted to CRAN) has changed the default value of one of its options to `NULL`. This makes the checked package fail `R CMD check`. This PR fixes that. `NULL != bquote()` returns `logical(0)` instead of `TRUE`, causing `vapply()` to error. Use `!identical(x, bquote())` which correctly returns a scalar logical for any value including NULL.
1 parent 2529cbd commit c20190c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

R/install.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ install_process <- R6::R6Class(
7373
callr_r_bg = function(...) {
7474
# default formal argument values
7575
options <- formals(callr::r_bg)
76-
options <- options[vlapply(options, `!=`, bquote())]
76+
options <- options[vlapply(options, function(x) !identical(x, bquote()))]
7777
options <- lapply(options, eval, envir = asNamespace("callr"))
7878

7979
# ellipsis arguments

0 commit comments

Comments
 (0)