Permalink
Browse files

Separated mysql and mysql2 adapters

  • Loading branch information...
1 parent c402c6d commit 517c17620a9dd169115d822a1162c57e8a347c1e @vihai vihai committed Jan 16, 2012
Showing with 3 additions and 14 deletions.
  1. +3 −14 lib/enum_column.rb
View
@@ -3,20 +3,9 @@ class EnumColumnRailtie < Rails::Railtie
initializer 'enum_column.initialize', :after => 'active_record.initialize_database' do |app|
ActiveSupport.on_load :active_record do
- if defined? ActiveRecord::ConnectionAdapters::MySQLJdbcConnection ||
- defined? ActiveRecord::ConnectionAdapters::Mysql2Adapter ||
- defined? ActiveRecord::ConnectionAdapters::MysqlAdapter
- require 'enum/mysql/adapter'
- require 'enum/mysql/enum_adapter'
- require 'enum/mysql/schema_statements'
- require 'enum/mysql/schema_definitions'
- end
-
- if defined? ActiveRecord::ConnectionAdapters::PostgreSQLAdapter
- require 'enum/pgsql/adapter'
- require 'enum/pgsql/enum_adapter'
- require 'enum/pgsql/schema_statements'
- end
+ require 'enum/mysql'
+ require 'enum/mysql2'
+ require 'enum/pgsql'
require 'enum/quoting'
require 'enum/validations'

0 comments on commit 517c176

Please sign in to comment.