Skip to content

Commit

Permalink
Fix a regular expression introduced by PR #393.
Browse files Browse the repository at this point in the history
  • Loading branch information
fweber144 committed Mar 22, 2023
1 parent 9a7b567 commit 6c8dcf7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/formula.R
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ parse_additive_terms <- function(terms) {
smooth <- unlist(lapply(smooth_terms, function(st) {
grep(make_function_regexp(st), terms, value = TRUE)
}))
if (any(grepl("\\(.+,.+=.+\\)", smooth))) {
if (any(grepl("\\(.+,.*=.+\\)", smooth))) {
stop("In s() and t2() terms, arguments other than predictors are not ",
"allowed.")
}
Expand Down

0 comments on commit 6c8dcf7

Please sign in to comment.