step-track 0.3.2 → 0.3.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 938ffda8b657d81d485136c973fd2eb2cb47a28e
4
- data.tar.gz: e657cf009b89a0311f0791d778d56e240404207e
3
+ metadata.gz: bc50b128bbf34ac66883d612e505726bbb4e9f64
4
+ data.tar.gz: f2575a7a94f5dbd39f985a0019bd7c94117fd271
5
5
  SHA512:
6
- metadata.gz: 2d25aa304e1a15513e932c6a4b3f9bdbbd630aac0d15961fbedd1f1387de7b2c6045e714292c7740340922f8e80f4be101caab05f5945a3987048a11a540fa43
7
- data.tar.gz: a0f2a894f9f140176f8345938a8015b4d9203396095fbe24023e5abbcc384175ad71af0d3aaa27d676a03a8929c610f55ad137ac852971dac90911d697ef7903
6
+ metadata.gz: cd7889d54b30b00638136ce29bb311e8608f46efe311ead7908ab5900ec772cc1734923ac94d5bf00c26e19e6d60ed3358620d3c92c3506ad1a542e0c5936cdf
7
+ data.tar.gz: 090e8bbd1cdee43a78498c6b844026ef543c0ee65c71e6b983e78d48d28c191efb8d2e9f9e9684adab30bcd04337c6a3419445649f807f29ed3951447f3a90fd
data/lib/step_track.rb CHANGED
@@ -36,7 +36,9 @@ module StepTrack
36
36
  steps = track_ref.delete(:steps)
37
37
  steps.each { |step| step.delete(:time) }
38
38
  result = {step_count: steps.count}
39
- result.merge!(steps.last || {})
39
+ last_step = steps.last&.dup || {}
40
+ last_step[:final_step_name] = last_step.delete(:step_name)
41
+ result.merge!(last_step)
40
42
  steps.each_with_index do |step, i|
41
43
  name = step.delete(:step_name)
42
44
  [:split, :duration].each { |k| step[k] = (step[k] * 1000).to_i }
@@ -1,3 +1,3 @@
1
1
  module StepTrack
2
- VERSION = "0.3.2"
2
+ VERSION = "0.3.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: step-track
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.2
4
+ version: 0.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthias Geier