Skip to content

Commit 091a650

Browse files
authored
Merge pull request #7 from madebylotus/master
Simplest fix for the no results exception on events search
2 parents 0afec62 + b4c2ccd commit 091a650

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

lib/ticketmaster/results/search.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ class Search < Result
33
attr_accessor :type
44

55
def results
6+
return [] if data['_embedded'].nil?
7+
68
data['_embedded'][type].map do |event|
79
Result.create(event, request, "Ticketmaster::#{type.capitalize.chop}")
810
end

0 commit comments

Comments
 (0)