]> git.openstreetmap.org Git - rails.git/blob - vendor/plugins/open_id_authentication/init.rb
Allow to not specify a password when signing up with openID
[rails.git] / vendor / plugins / open_id_authentication / init.rb
1 if config.respond_to?(:gems)
2   config.gem 'ruby-openid', :lib => 'openid', :version => '>=2.0.4'
3 else
4   begin
5     require 'openid'
6   rescue LoadError
7     begin
8       gem 'ruby-openid', '>=2.0.4'
9     rescue Gem::LoadError
10       puts "Install the ruby-openid gem to enable OpenID support"
11     end
12   end
13 end
14
15 config.to_prepare do
16   OpenID::Util.logger = Rails.logger
17   ActionController::Base.send :include, OpenIdAuthentication
18 end