Sha256: cb75d5303cf46bba2b3a2e045eab4a951ec1f96719780c497b546eda06395c63

Contents?: true

Size: 330 Bytes

Versions: 7

Compression:

Stored size: 330 Bytes

Contents

module Toro
  module Middleware
    module Server
      class Properties
        def call(job, worker)
          result = yield
          if result.is_a?(Hash) && result[:job_properties].is_a?(Hash)
            job.set_properties(result[:job_properties])
            job.save
          end
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
toro-0.2.2 lib/toro/middleware/server/properties.rb
toro-0.2.1 lib/toro/middleware/server/properties.rb
toro-0.2.0 lib/toro/middleware/server/properties.rb
toro-0.1.1 lib/toro/middleware/server/properties.rb
toro-0.1.0 lib/toro/middleware/server/properties.rb
toro-0.0.3 lib/toro/middleware/server/properties.rb
toro-0.0.2 lib/toro/middleware/server/properties.rb