Sha256: 5b3c41cc26b787e759bc9aa306822a07d936c37ffe3a0dca9c0b971c5b91349a

Contents?: true

Size: 319 Bytes

Versions: 3

Compression:

Stored size: 319 Bytes

Contents

module RailsAdminContent
  module Mysql
    module Adapters
      class Client
        def initialize
          @client ||= Mysql2::Client.new ActiveRecord::Base.connection_config
        end

        def query(sql)
          @client.query(sql).each
        rescue
          []
        end
      end

    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
rails_admin_content-0.2.4 lib/rails_admin_content/mysql/adapters/client.rb
rails_admin_content-0.2.3 lib/rails_admin_content/mysql/adapters/client.rb
rails_admin_content-0.2.2 lib/rails_admin_content/mysql/adapters/client.rb