Skip to content

Commit fa40f0a

Browse files
committed
be more specific in testing of LiblineaR penalty
1 parent c9a5ba5 commit fa40f0a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

R/logistic_reg.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,10 +154,10 @@ check_args.logistic_reg <- function(object, call = rlang::caller_env()) {
154154
)
155155
}
156156

157-
if ((!is.null(args$penalty)) && args$penalty <= 0) {
157+
if ((!is.null(args$penalty)) && args$penalty == 0) {
158158
cli::cli_abort(
159159
"For the {.pkg LiblineaR} engine, {.arg penalty} must be {.code > 0}, \\
160-
not {args$penalty}.",
160+
not 0.",
161161
call = call
162162
)
163163
}

0 commit comments

Comments
 (0)