libis-workflow-mongoid 2.0.23 → 2.0.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 08b193e063d710321a723fae1561fdb9f7bb4bdb
4
- data.tar.gz: 414358f454bc0094a6e1132399cec90eb5be455a
3
+ metadata.gz: 741810e46242c967f9e6d037b5f4d49bdbf9d007
4
+ data.tar.gz: cb4ecc74d6e52f9ae8dcfcf22bf07ffc7d7d896a
5
5
  SHA512:
6
- metadata.gz: 0058c98a7a750805a93bb7a267b181e82f0af8a1aa9b40dc342a80e7b46e81ebb84e69c93d6e00029ac4d354be7ca6adbd28261b5488729e2081d59f420b2ea3
7
- data.tar.gz: 80fda526c90b79eaaa8c01fbcf7d43d0312b8688218a811a0e69b56afb3e3d7efe88269f5700d42ff97c141d604ff3f2e16d48b7a710e059aa1dbcd39c145d47
6
+ metadata.gz: a397bf2c8b23b432958884d5b8b5f55f623c1b043b4bfc205960b1e73ac9e2e37aa3e8966ad18dc29b6017e47fb41acb3fc48cac241ea9f3b58d1aad5e689eba
7
+ data.tar.gz: 0b945a420ac941b51a39c83b022ce8f283c675b824f57d57b5f5c06119824a1c2f89aa4deebd044a2a840ca35cb2f7c55756d0f763ad29f73dc86f34b4308a86
@@ -20,7 +20,7 @@ module Libis
20
20
 
21
21
  belongs_to :job, polymorphic: true
22
22
 
23
- index({job_id: 1, job_type: 1, start_date: 1}, {sparse:1, name: 'by_job'})
23
+ index({job_id: 1, job_type: 1, start_date: 1}, {sparse: 1, name: 'by_job'})
24
24
 
25
25
  set_callback(:destroy, :before) do |document|
26
26
  document.rm_workdir
@@ -82,11 +82,11 @@ module Libis
82
82
  end
83
83
 
84
84
  def name
85
- [
86
- (self.run_name || self.job.name),
87
- self.id.generation_time.strftime('%Y%m%d-%H%M%S'),
88
- self.id.to_s[8..-1]
89
- ].reject { |x| x.blank? }.join('-')
85
+ parts = [self.job.name]
86
+ parts << self.run_name unless self.run_name.blank?
87
+ parts << self.id.generation_time.strftime('%Y%m%d-%H%M%S')
88
+ parts << self.id.to_s[8..-1] if self.run_name.blank?
89
+ parts.join('-')
90
90
  rescue
91
91
  self.id.to_s
92
92
  end
@@ -1,7 +1,7 @@
1
1
  module Libis
2
2
  module Workflow
3
3
  module Mongoid
4
- VERSION = '2.0.23' unless const_defined? :VERSION # the guard is against a redefinition warning that happens on Travis
4
+ VERSION = '2.0.24' unless const_defined? :VERSION # the guard is against a redefinition warning that happens on Travis
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: libis-workflow-mongoid
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.23
4
+ version: 2.0.24
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kris Dekeyser