Sha256: 4c38ad1ffbc980c6c8a58e5b7fad5103fd95f9d825b08eee0dcd87f045e4751a

Contents?: true

Size: 271 Bytes

Versions: 5

Compression:

Stored size: 271 Bytes

Contents

module Harvesting
  module Models
    class HarvestRecord < Base

      def save
        id.nil? ? create : update
      end

      def create
        harvest_client.create(self)
      end

      def update
        harvest_client.update(self)
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
harvesting-0.6.0 lib/harvesting/models/harvest_record.rb
harvesting-0.5.1 lib/harvesting/models/harvest_record.rb
harvesting-0.5.0 lib/harvesting/models/harvest_record.rb
harvesting-0.4.0 lib/harvesting/models/harvest_record.rb
harvesting-0.3.0 lib/harvesting/models/harvest_record.rb