我的代码:
require 'rubygems'
require 'basecamp'
basecamp = Basecamp.establish_connection!('example.basecamphq.com', 'example', '123456', true)
projects = Basecamp::Project.find(:all)
projects.inspect
它给:
/Users/kir/.rvm/gems/ruby-1.8.7-p352@project/gems/activeresource-3.1.0/lib/active_resource/base.rb:922:in `instantiate_collection': undefined method `collect!' for #<Hash:0x105faa450> (NoMethodError)
from /Users/kir/.rvm/gems/ruby-1.8.7-p352@project/gems/activeresource-3.1.0/lib/active_resource/base.rb:894:in `find_every'
from /Users/kir/.rvm/gems/ruby-1.8.7-p352@project/gems/activeresource-3.1.0/lib/active_resource/base.rb:806:in `find'
from bs.rb:4
我的代码有什么问题?