Skip to content

Instantly share code, notes, and snippets.

@nov
Created May 7, 2010 01:18
Show Gist options
  • Save nov/392901 to your computer and use it in GitHub Desktop.
Save nov/392901 to your computer and use it in GitHub Desktop.
require 'rubygems'
require 'fb_graph'
ACCESS_TOKEN = "..."
begin
me = FbGraph::User.me(ACCESS_TOKEN)
album = me.albums.first
photo = album.photo!(
:access_token => ACCESS_TOKEN,
:image => File.new(File.join(File.dirname(__FILE__), 'nov.gif')),
:message => 'Hello, where is photo?'
)
puts photo.inspect
rescue => e
puts e.body
end
@nov
Copy link
Author

nov commented May 7, 2010

Umm, this error message isn't helpful :(
As you mentioned, rest-client gem seems had an issue.
http://github.com/archiloque/rest-client/issues/issue/17

Can you try to install newest rest-client master branch?
It might solve your problem.
http://gist.github.com/393345

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment