@@ -3190,7 +3190,7 @@ function(dir, force_suggests = TRUE, check_incoming = FALSE,
31903190            installed_in  <-  c(installed_in , rep.int(lib , length(pkgs )))
31913191        }
31923192        if  (length(lreqs )) {
3193-             reqs  <-  unique(sapply (lreqs , `[[` , 1L ))
3193+             reqs  <-  unique(vapply (lreqs , `[[` ,  " " 1L ))
31943194            bad  <-  setdiff(reqs , installed )
31953195            if (length(bad )) {
31963196                # # EDanalysis has a package in all of Depends, Imports, Suggests.
@@ -3226,12 +3226,12 @@ function(dir, force_suggests = TRUE, check_incoming = FALSE,
32263226        if  (length(lenhances ) && 
32273227            ! config_val_to_logical(Sys.getenv(" _R_CHECK_PACKAGE_DEPENDS_IGNORE_MISSING_ENHANCES_" 
32283228                                             " FALSE" 
3229-             m  <-  setdiff(sapply (lenhances , `[[` , 1L ), installed )
3229+             m  <-  setdiff(vapply (lenhances , `[[` ,  " " 1L ), installed )
32303230            if (length(m ))
32313231                bad_depends $ enhances_but_not_installed  <-  m 
32323232        }
32333233        if  (! force_suggests  &&  length(lsuggests )) {
3234-             m  <-  setdiff(sapply (lsuggests , `[[` , 1L ), installed )
3234+             m  <-  setdiff(vapply (lsuggests , `[[` ,  " " 1L ), installed )
32353235            if (length(m ))
32363236                bad_depends $ suggests_but_not_installed  <-  m 
32373237        }
@@ -3345,12 +3345,12 @@ function(dir, force_suggests = TRUE, check_incoming = FALSE,
33453345        # # First use dependencies which are installed: strict dependencies
33463346        # # need to be for a full check.
33473347        # # Suggests might not even exist, so we suppress warnings.
3348-         mt  <-  utils :: maintainer 
3349-         strict2  <-  sapply (strict , function ( x ) suppressWarnings(mt( x )) )
3348+         mt  <-  function ( x ) suppressWarnings( utils :: maintainer( x )) 
3349+         strict2  <-  vapply (strict , mt ,  " " 
33503350        miss1  <-  is.na(strict2 )
33513351        weak  <-  setdiff(as.character(suggests ),
33523352                        bad_depends $ suggested_but_not_installed )
3353-         weak2  <-  sapply (weak , function ( x ) suppressWarnings(mt( x )) )
3353+         weak2  <-  vapply (weak , mt ,  " " 
33543354        miss2  <-  is.na(weak2 )
33553355        if ((any(miss1 ) ||  any(miss2 )) && 
33563356           ! inherits(tryCatch(db  <-  CRAN_package_db()[, c(" Package" 
0 commit comments