Skip to content

Commit

Permalink
fix typo in error message
Browse files Browse the repository at this point in the history
  • Loading branch information
torfjelde committed Sep 14, 2023
1 parent e897b8a commit 33f9bb7
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/sample.jl
Original file line number Diff line number Diff line change
Expand Up @@ -540,7 +540,9 @@ tighten_eltype(x::Vector{Any}) = map(identity, x)

check_initial_params(x::Nothing, n::Int) = nothing
function check_initial_params(x, n::Int)
length(x) == n || throw(
ArgumentError("not enough initial parameters (expected $n, received $(length(y))"),
)
if length(x) != n
throw(
ArgumentError("not enough initial parameters (expected $n, received $(length(x))"),
)
end
end

0 comments on commit 33f9bb7

Please sign in to comment.