Sha256: 40a4f3d7f1c0bc81c009e7433e11fec94012bff0c0f03e4af763da9fe590588b

Contents?: true

Size: 293 Bytes

Versions: 1

Compression:

Stored size: 293 Bytes

Contents

module Grimm
  class DatabaseConnector

    def self.connect_db
      @@db = SQLite3::Database.new File.join "db", "grimm.db"
    end

    def self.execute(query, args =  nil)
      @@db ||= connect_db
      return @@db.execute(query, args) if args
      @@db.execute(query)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
grimm-0.0.3 lib/grimm/orm/database_connector.rb