lib/musicbrainz/models/release_group.rb in musicbrainz-0.7.6 vs lib/musicbrainz/models/release_group.rb in musicbrainz-0.7.7
- old
+ new
@@ -33,10 +33,10 @@
end
end
def find_by_artist_and_title(artist_name, title, type = nil )
matches = search(artist_name, title, type)
- matches.empty? ? nil : find(matches.first[:id])
+ matches.nil? || matches.empty? ? nil : find(matches.first[:id])
end
end
end
end