Skip to content
Snippets Groups Projects
Verified Commit 016d0b5a authored by Tamas Gal's avatar Tamas Gal :speech_balloon:
Browse files

Final fix for missing header entries

parent 2e19aa2d
No related branches found
No related tags found
No related merge requests found
......@@ -100,7 +100,7 @@ Base.propertynames(h::MCHeader) = Symbol.(keys(h._raw))
function Base.getproperty(h::MCHeader, s::Symbol)
s == :_raw && return getfield(h, s)
if s propertynames(h)
values = [ismissing(v) ? missing : tonumifpossible(v) for v split(strip(h._raw[String(s)]))]
values = Union{AbstractString, Missing}[tonumifpossible(v) for v split(strip(h._raw[String(s)]))]
if s keys(MCHEADERDEF)
fieldnames = collect(MCHEADERDEF[s])
# fill up with missing if not all fields are provided
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment