1
0
Fork 0
mirror of https://github.com/MillironX/XAM.jl.git synced 2024-11-14 22:33:14 +00:00

Correct not found check

This commit is contained in:
Ciarán O'Mara 2020-05-22 12:11:46 +10:00
parent cc18311539
commit 8b7a2ecc2b

View file

@ -47,7 +47,7 @@ end
function Base.iterate(iter::OverlapIterator) function Base.iterate(iter::OverlapIterator)
refindex = findfirst(isequal(iter.refname), iter.reader.refseqnames) refindex = findfirst(isequal(iter.refname), iter.reader.refseqnames)
if refindex == 0 if refindex === nothing
throw(ArgumentError("sequence name $(iter.refname) is not found in the header")) throw(ArgumentError("sequence name $(iter.refname) is not found in the header"))
end end
@assert iter.reader.index !== nothing @assert iter.reader.index !== nothing