Skip to content
Open
Changes from all 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
8 changes: 4 additions & 4 deletions lib/siriproxy-arduino.rb
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def show_info(number)

show_info = JSON.parse(page)

if show['title'].nil?
if show_info['title'].nil?
#didn't find info playing about the current show
#so go back a half hour until
#we find valid info from the start of the show
Expand All @@ -125,18 +125,18 @@ def show_info(number)

answer_content = Array.new(
SiriAnswerLine.new('logo', self.image_prefix + channel_id + '.png'),
SiriAnswerLine.new(show['title'])
SiriAnswerLine.new(show_info['title'])
)

answer_content << SiriAnswerLine.new(show['programDescription']) unless show['programDescription'].nil?
answer_content << SiriAnswerLine.new(show_info['programDescription']) unless show_info['programDescription'].nil?

answer = SiriAnswer.new(channel[0][:name], answer_content)

object.views << SiriAnswerSnippet.new([answer])

send_object object

response = ask "Would you like to watch #{show['title']}"
response = ask "Would you like to watch #{show_info['title']}"

if(response =~ /yes/i)
change_channel number
Expand Down