This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

Fixing `cheer` script

This script was broken due a change at imgur's API json representation. Now the JSON returns the encapsulated images gallery as a `data` element. This error was causing hubot to hang everytime someone tried to use this script
  • Loading branch information...
pellegrino committed Dec 19, 2012
1 parent 9870aee commit 4fb03292b648356273d2194d90584318e27a013a
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/scripts/cheer.coffee
View
@@ -26,6 +26,6 @@ aww = (msg) ->
.http('http://imgur.com/r/aww.json')
.get() (err, res, body) ->
images = JSON.parse(body)
- images = images.gallery
+ images = images.data
image = msg.random images
msg.send "http://i.imgur.com/#{image.hash}#{image.ext}"

0 comments on commit 4fb0329

Please sign in to comment.