Class: AMEE::Rails::Connection
- Inherits:
-
Object
- Object
- AMEE::Rails::Connection
- Defined in:
- lib/amee/rails.rb
Class Method Summary collapse
Class Method Details
.global(options = {}) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/amee/rails.rb', line 9 def self.global( = {}) unless @connection $AMEE_CONFIG ||= {} # Make default values nil if $AMEE_CONFIG['ssl'] == false .merge! :ssl => false end @connection = self.connect($AMEE_CONFIG['server'], $AMEE_CONFIG['username'], $AMEE_CONFIG['password'], ) # Also store as $amee for backwards compatibility, though this is now deprecated $amee = @connection end @connection end |