Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hotfix Moov parser #178

Merged
merged 4 commits into from
Oct 5, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/format_parser/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module FormatParser
VERSION = '0.25.1'
VERSION = '0.25.2'
end
2 changes: 1 addition & 1 deletion lib/parsers/moov_parser/decoder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def as_json(*a)
# matches the type, drilling down if a list of atom names is given
def find_first_atom_by_path(atoms, *atom_types)
type_to_find = atom_types.shift
requisite = atoms.find { |e| e.atom_type == type_to_find }
requisite = atoms.find { |e| e.is_a?(Atom) && e.atom_type == type_to_find }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still not understand why the commit 2c8adbf broke it, but this change fix the problem!


# Return if we found our match
return requisite if atom_types.empty?
Expand Down