thomasp85 / fiery

A flexible and lightweight web server
https://fiery.data-imaginist.com
Other
244 stars 12 forks source link

FYI: parallelly::supportsMulticore() #52

Open HenrikBengtsson opened 1 year ago

HenrikBengtsson commented 1 year ago

FYI, instead of:

can_fork <- NULL
#' @importFrom parallelly availableCores
on_load({can_fork <- availableCores("multicore") > 1L})

you could use parallelly::supportsMulticore(). Other than being more clear, the advantage would be to that it returns TRUE also when there's a single core available.