Skip to content

Commit 33f9bb7

Browse files
committed
fix typo in error message
1 parent e897b8a commit 33f9bb7

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/sample.jl

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -540,7 +540,9 @@ tighten_eltype(x::Vector{Any}) = map(identity, x)
540540

541541
check_initial_params(x::Nothing, n::Int) = nothing
542542
function check_initial_params(x, n::Int)
543-
length(x) == n || throw(
544-
ArgumentError("not enough initial parameters (expected $n, received $(length(y))"),
545-
)
543+
if length(x) != n
544+
throw(
545+
ArgumentError("not enough initial parameters (expected $n, received $(length(x))"),
546+
)
547+
end
546548
end

0 commit comments

Comments
 (0)