Skip to content

Commit

Permalink
Fix rest-client require
Browse files Browse the repository at this point in the history
  • Loading branch information
tapajos committed Jul 1, 2010
1 parent e14bdfd commit dda61c1
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions lib/couchrest.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,12 @@
rescue LoadError
raise "No compatible json library found, install either json or json_pure gem" unless Kernel.const_defined?("JSON")
end
require 'rest_client'
begin
require 'rest_client'
rescue LoadError
raise "You neet to install rest_client to use couchrest"
end


# Not sure why this is required, so removed until a reason is found!
$:.unshift File.dirname(__FILE__) unless
Expand Down Expand Up @@ -136,6 +141,4 @@ def self.inherited(subclass)
raise "ExtendedDocument is no longer included in CouchRest base driver, see couchrest_extended_document gem"
end

end


end

0 comments on commit dda61c1

Please sign in to comment.