lib/hybag.rb in hybag-0.0.11 vs lib/hybag.rb in hybag-0.1.0

- old
+ new

@@ -8,10 +8,12 @@ require 'hybag/bag_writer' require 'hybag/ingester' module Hybag def self.ingest(bag) - Hybag::Ingester.new(bag).ingest + ingester = Hybag::Ingester.new(bag) + yield(ingester) if block_given? + ingester.ingest end # Error Classes class UndiscoverableModelName < StandardError def initialize(bag)