Module: Grande::UseSequel

Defined in:
lib/grande/use_sequel.rb,
lib/grande/use_sequel_with_pg.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#dbObject (readonly)

Returns the value of attribute db.



7
8
9
# File 'lib/grande/use_sequel_with_pg.rb', line 7

def db
  @db
end

Instance Method Details

#setup_sequel_connectionObject



9
10
11
12
13
# File 'lib/grande/use_sequel_with_pg.rb', line 9

def setup_sequel_connection
  db_url = @config_loader.get_str!("database.url")
  @db = Sequel.connect(db_url)
  @db.extension(:pg_json)
end