mirror of
https://github.com/MillironX/XAM.jl.git
synced 2024-11-23 02:09:55 +00:00
Flatten elseif
This commit is contained in:
parent
ef99c70317
commit
789cccbaff
3 changed files with 6 additions and 6 deletions
|
@ -67,7 +67,8 @@ function Base.iterate(iter::OverlapIterator, state)
|
|||
c = compare_intervals(state.record, (state.refindex, iter.interval))
|
||||
if c == 0
|
||||
return copy(state.record), state
|
||||
elseif c > 0
|
||||
end
|
||||
if c > 0
|
||||
# no more overlapping records in this chunk since records are sorted
|
||||
break
|
||||
end
|
||||
|
|
|
@ -30,10 +30,8 @@ end
|
|||
function Reader(input::IO; index=nothing)
|
||||
if isa(index, AbstractString)
|
||||
index = BAI(index)
|
||||
else
|
||||
if index != nothing
|
||||
error("unrecognizable index argument")
|
||||
end
|
||||
elseif index != nothing
|
||||
error("unrecognizable index argument")
|
||||
end
|
||||
reader = init_bam_reader(input)
|
||||
reader.index = index
|
||||
|
|
|
@ -163,7 +163,8 @@ function checked_refid(record::Record)
|
|||
id = refid(record)
|
||||
if id == 0
|
||||
throw(ArgumentError("record is not mapped"))
|
||||
elseif !isdefined(record, :reader)
|
||||
end
|
||||
if !isdefined(record, :reader)
|
||||
throw(ArgumentError("reader is not defined"))
|
||||
end
|
||||
return id
|
||||
|
|
Loading…
Reference in a new issue