Class: Peatio::Command::DB::Create

Inherits:
Base
  • Object
show all
Defined in:
lib/peatio/command/db.rb

Instance Method Summary collapse

Methods inherited from Base

#say, #sql_client

Instance Method Details

#executeObject


3
4
5
6
7
# File 'lib/peatio/command/db.rb', line 3

def execute
  client = Peatio::Sql::Client.new
  database_name = client.config.delete(:database)
  Peatio::Sql::Schema.new(client.connect).create_database(database_name)
end