Skip to content

Commit

Permalink
reformat error message
Browse files Browse the repository at this point in the history
  • Loading branch information
rafapereirabr committed Mar 8, 2021
1 parent 289ec88 commit 8b664ba
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions r-package/R/setup_r5.R
Expand Up @@ -43,12 +43,14 @@ setup_r5 <- function(data_path,
rJava::.jinit()
ver <- rJava::.jcall("java.lang.System","S","getProperty","java.version")
ver <- as.numeric(gsub("\\..*","",ver))
if (ver != 11){stop("This package requires the Java SE Development Kit 11.
Please update your Java installation. The jdk 11 can be
downloaded from either:
- openjdk: https://jdk.java.net/java-se-ri/11
- oracle: https://www.oracle.com/java/technologies/javase-jdk11-downloads.html")}

if (ver < 11){
stop(
"This package requires the Java SE Development Kit 11.\n",
"Please update your Java installation. The jdk 11 can be downloaded from either:\n",
" - openjdk: https://jdk.java.net/java-se-ri/11\n",
" - oracle: https://www.oracle.com/java/technologies/javase-jdk11-downloads.html"
)
}

# check directory input
if (is.null(data_path)){ stop("Please provide data_path.")}
Expand Down

0 comments on commit 8b664ba

Please sign in to comment.