Sha256: 7a4f432792ed36a02ac89a5be3b398f62c8717d990d4a69adeee95fd2ca75a29

Contents?: true

Size: 294 Bytes

Versions: 1

Compression:

Stored size: 294 Bytes

Contents

module Replicat
  module Model
    def replicate(connection_name = nil)
      raise "You must set `connection_name` of this model class." if !connection_name && !defined?(Rails)
      include Replicat::Replicable
      self.connection_name = connection_name || Rails.env.to_s
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
replicat-0.0.1 lib/replicat/model.rb