Skip to content

Commit 5b0acfd

Browse files
committed
* r/R/utils.R (is_wholenumber): Handle vector inputs using & instead of &&.
1 parent 8a4bb43 commit 5b0acfd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

r/R/utils.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ as_double_matrix_1 <- function(x)
8787
}
8888

8989
is_wholenumber <- function(x, tol = .Machine$double.eps^0.5)
90-
is.finite(x) && abs(x - round(x)) < tol
90+
is.finite(x) & (abs(x - round(x)) < tol)
9191

9292
as_integer <- function(x)
9393
{

0 commit comments

Comments
 (0)