Skip to content

Commit

Permalink
refactor: rm call. = FALSE arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
gisler committed Jan 2, 2025
1 parent 7ec9ccf commit bb173a7
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 14 deletions.
2 changes: 1 addition & 1 deletion R/aaa.R
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ setMethod(
arguments <- readParameters(arguments)
argumentNames <- names(arguments)
} else if (.Object@ls_ini) {
stop('"parameters.yaml" file does not exist.', call. = FALSE)
stop('"parameters.yaml" file does not exist.')
}
arguments <- arguments[setdiff(
argumentNames,
Expand Down
2 changes: 1 addition & 1 deletion R/gettersSetters.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ setMethod(
}
}

stop(sprintf("Layer %s was not found.", deparse(i)), call. = FALSE)
stop(sprintf("Layer %s was not found.", deparse(i)))
}
)
#' @rdname getLayer-RPhosFate-method
Expand Down
11 changes: 3 additions & 8 deletions R/input.R
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,7 @@ demoProject <- function(cs_dir = tempdir(TRUE)) {
demoRoot <- file.path(cs_dir, "demoProject")

if (dir.exists(demoRoot)) {
warning(
'A folder called "demoProject" already exists and is left as is.',
call. = FALSE
)
warning('A folder called "demoProject" already exists and is left as is.')
} else {
dir.create(demoRoot)
testRoot <- system.file("tinytest", "testProject", package = "RPhosFate")
Expand Down Expand Up @@ -168,15 +165,13 @@ DEMrelatedInput <- function(
packageVersion("whitebox") < package_version("2.0.0")) {
stop(
'Package "whitebox" (v2.0.0 or higher) must be installed for this ',
"functionality.",
call. = FALSE
"functionality."
)
}
if (!whitebox::check_whitebox_binary()) {
stop(
'The "WhiteboxTools" binary must be installed for this functionality. ',
'Consider calling "whitebox::install_whitebox()" first.',
call. = FALSE
'Consider calling "whitebox::install_whitebox()" first.'
)
}
qassert(cv_dir, "S+")
Expand Down
3 changes: 1 addition & 2 deletions R/interface.R
Original file line number Diff line number Diff line change
Expand Up @@ -659,8 +659,7 @@ setMethod(
if (any(abs(interval - value[[1L]]) <= tol)) {
warning(
"Parameter approximately within tolerance of interval end-point. ",
"Optimum may not have been found.",
call. = FALSE
"Optimum may not have been found."
)
}

Expand Down
3 changes: 1 addition & 2 deletions R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,7 @@ readParameters <- function(arguments) {

warning(
'Omitted parameter "iv_fDo", as it is no longer required. ',
"It will definitely be lost upon saving the project's state.",
call. = FALSE
"It will definitely be lost upon saving the project's state."
)
}

Expand Down

0 comments on commit bb173a7

Please sign in to comment.